Closed hymair closed 2 years ago
Adding this did not fix the error.
// nuxt.config.ts
build: {
babel: {
compact: true,
},
loaders: {
vue: {
compiler: require('vue-template-babel-compiler'),
},
},
}
🤔 This msg seems to be just a warning
from babel?
Does it have any negative impact for you?
If you don't want to see this warning msg, you can add compact: true
to babel options like this: https://github.com/JuniorTour/vue-template-babel-compiler/blob/main/doc/Usage.md#1-babel-options-customization
// nuxt.config.js
export default {
// Build Configuration: https://go.nuxtjs.dev/config-build
build: {
loaders: {
vue: {
compilerOptions: {
babelOptions: {
compact: true,
},
},
compiler: require('vue-template-babel-compiler')
}
},
},
// ...
}
compact: true
hides the error but I had to add @ts-ignore
as there was a type error.
Type '{ babelOptions: { compact: true; }; }' is not assignable to type 'CompilerOptions'.
Object literal may only specify known properties, and 'babelOptions' does not exist in type 'CompilerOptions'.
Info
Only used optional chaining. Exactly 23 occurrences total in 4 different files.
Extra