Developing Vue using an equivalent subset of TSX as the template language #511
DiamondYuan
started this conversation in
General
Replies: 1 comment 4 replies
-
Vue already supports JSX / TSX ? |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
Choose a subset of TSX syntax as the template language for Vue. This subset has the following constraints:
This syntax subset is equivalent to the Vue template language. During Vue compilation, we can first convert TSX into a Vue template, and then compile the template into JavaScript. This way, we can enjoy the performance of Vue and the type hints of TSX.
This approach is more like a syntax sugar for Vue templates, as users can easily convert TSX to Vue templates at any time.
Beta Was this translation helpful? Give feedback.
All reactions