Skip to content

feat: RFC 436 Leaves Experimental #2545

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 3 commits into from
Mar 25, 2023
Merged

feat: RFC 436 Leaves Experimental #2545

merged 3 commits into from
Mar 25, 2023

Conversation

johnsoncodehk
Copy link
Member

@johnsoncodehk johnsoncodehk commented Mar 24, 2023

Follow-up to #1964

  • No needed generic="T extends any" and more, just generic="T"
  • Deprecated experimentalRfc436 flag, judging only based on whether there is a generic attr
  • Workaround for JSX issues in template #592 when enabled jsxTemplates: /** @jsxImportSource vue */

Requirement

  • Volar / vue-tsc: >= 1.3.7
  • Vue: >= 3.3.0-alpha.5

Changes

  • tsconfg.json
{
-   "vueCompilerOptions": {
-     "jsxTemplates": true,
-     "experimentalRfc436": true
-   }
}
  • Component
- <script setup lang="ts" generic="T extends any">
+ <script setup lang="ts" generic="T">
defineProps<{ msg: T }>()
</script>

If in doubt about codegen behavior, you can inspect the virtual code with the Volar (Debug): Show Virtual Files command.

@johnsoncodehk johnsoncodehk changed the title feat: deprecated experimentalRfc436 flag feat: RFC 436 Leaves Experimental Mar 24, 2023
@johnsoncodehk johnsoncodehk marked this pull request as ready for review March 25, 2023 00:08
@johnsoncodehk johnsoncodehk merged commit 836043a into master Mar 25, 2023
@johnsoncodehk johnsoncodehk deleted the rfc436 branch March 25, 2023 00:17
@yyx990803 yyx990803 mentioned this pull request Mar 26, 2023
5 tasks
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant