We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用 setup 的写法, Demo 就会报错了, 好像这种代码会被放到 scriptSetup 属性中, 而不是 script 里面 ?
setup
scriptSetup
script
<noscript type="vue-sfc" component="MyComponent" mount="#app"> <script setup> import {ref, } from 'vue'; let count = ref(0); </script> <template> <button @click="count++">Count is: {{ count }}</button> </template> <style scoped> button {font-weight: bold;} </style> </noscript> <div id="app"></div> <script src="https://unpkg.com/noscript-sfc/index.js"></script>
# 错误信息 vue.esm-browser.js:1513 [Vue warn]: Cannot mutate <script setup> binding "count" from Options API.
The text was updated successfully, but these errors were encountered:
fix: 支持 setup
01b3f8b
Fixed xitu#4
832d3e1
Successfully merging a pull request may close this issue.
使用
setup
的写法, Demo 就会报错了, 好像这种代码会被放到scriptSetup
属性中, 而不是script
里面 ?The text was updated successfully, but these errors were encountered: