Optimized Vue 3 JSX support in 2.0
See original GitHub issuevite
version: 2.0 bata1- Operating System: mac os
- Node version: 14.15
When I change App.vue to App.tsx or App.jsx, the error “Uncaught ReferenceError: React is not defined” appears after running
Below is my code,this code is completely feasible in version 1.x
// src/App.tsx
export default () => {
return <div>App</div>
}
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Render Functions & JSX | Vue.js
create-vue and Vue CLI both have options for scaffolding projects with pre-configured JSX support. If you are configuring JSX manually, please refer to...
Read more >Template Syntax | Vue.js
Under the hood, Vue compiles the templates into highly-optimized JavaScript code ... write render functions instead of templates, with optional JSX support.
Read more >Frequently Asked Questions - Vue.js
If you are starting a new project today, Vue 3 is the recommended choice. There are only a few reasons for you to...
Read more >Single-File Components - Vue.js
IDE support with auto-completion and type-checking for template expressions; Out-of-the-box Hot-Module Replacement (HMR) support. SFC is a defining feature of ...
Read more >Production Deployment - Vue.js
When deploying to production, we should drop all the unused, development-only code branches for smaller payload size and better performance. Without Build Tools ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
b5b1496 added
esbuild.jsxInject
so you can specify auto-injected helper imports.Now provided via https://github.com/vitejs/vite/tree/main/packages/plugin-vue-jsx with HMR and Vue-dedicated transforms.