Skip to content
New issue

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

feat(vue-template)!: auto unwrap refs #72

Merged
merged 1 commit into from Jun 22, 2022
Merged

Conversation

antfu
Copy link
Member

@antfu antfu commented Jun 12, 2022

Solve the caveat mentioned in #15

Requiring adding .value was verbose and obeyed the direction for Vue to have reactivity transform. With this PR, auto imports in vue template are now auto unref, making it works just like in <script setup>. The caveat then becomes that you can't assign to auto imported ref, which we had correct types to cover it (readonly).

@antfu antfu merged commit 741015b into main Jun 22, 2022
@antfu antfu deleted the feat/vue-template-auto-unwrap branch June 22, 2022 20:29
antfu added a commit to unplugin/unplugin-auto-import that referenced this pull request Jun 22, 2022
@kevin82222
Copy link

How can it use in Svelte?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants