Subscribe on changes!

<script lang="tsx" setup> The page has no hot updates But <script lang="tsx"> is ok

avatar
Dec 15th 2021

Version

3.2.26

Reproduction link

sfc.vuejs.org/

Steps to reproduce

 I created the project with vite and installed @ vitejs / plugin Vue JSX and typescript, vue3 2.26. In < script lang = "TSX" setup >, create an array object with reactive two-way binding. Modify the ‘label’ field of the first object in the code and save the code. However, the web page is not hot updated and needs to be refreshed before it can be updated, but you can use < script lang = "TSX" >

Exports with definecomponent are hot updated. I don't know if there is a problem with my vite configuration or writing method Woo woo woo~~

The codes that cannot be hot updated are as follows:

Code that can be hot updated:

What is expected?

It is expected that the label of the array object is modified and the code is saved. The web page should be updated in real time, but < script lang = "TSX" setup > can't, < script lang = "TSX" > can

What is actually happening?

< script lang = "TSX" setup > can't hot update, < script lang = "TSX" > can hot update

avatar
Mar 9th 2022

看着知乎的百万年薪大佬们在vue3里面写jsx或tsx实在难受,要是支持这个