Open DamianGlowala opened 1 year ago
It seems that the
v-model:is-open="
isWatchYouTubeEmployerTalkVideoModalOpen
"
should be changed to
v-model:is-open="isWatchYouTubeEmployerTalkVideoModalOpen"
This is how Prettier formats my code and there should be no issue with that. Notice how lengthy the variable name is (hence splitting into a separate line). The latter example you included is indeed what I need to do manually to build the application.
This looks like an edge case that only fails in a specific situation. Modyfing the code slightly (e.g. removing some elements) will make this error disappear, but I still see no reason for it to fail in the included reproduction.
I had the same problem. This problem seems to occur when the character constant used to specify the variable name contains spaces.
I had the same problem when building nuxt in production. This error appears only with ref-value variables. When using reactive variable there is no error.
I have the same problem as well. I don't concider changing code format to one line as a fix as this would be very unstable solution. Who is responsible for this issue, is it esbuild or vite directly?
It seems that the
v-model:is-open=" isWatchYouTubeEmployerTalkVideoModalOpen "
should be changed to
v-model:is-open="isWatchYouTubeEmployerTalkVideoModalOpen"
I was getting error while npm run build which were Nuxt Build Error: [vite:define] Transform failed with 5 errors: ERROR: Invalid assignment target
fixing v-model structure solved my issue
Really hope this gets fixed because I lost some time trying to find out what was that 😥
Vue version
3.3.2
Link to minimal reproduction
https://github.com/DamianGlowala/nuxt-invalid-asignment-target-repro
Steps to reproduce
npm install
npm run build
What is expected?
Project successfully building for production.
What is actually happening?
System Info
Any additional comments?
It works fine in development.