How to suppress warning with __FEATURE_ESM_BUNDLER_WARN__ ?
See original GitHub issueThis might not be a bug, but maybe a missing part of the docs. I am using Vue 3 with Vue CLI and a vue.config.js. I had no luck adding it to chainWebpack like this, so how do I configure that flag?
chainWebpack: config => {
config.plugin('define').tap(args => {
args[0] = {
...args[0],
__FEATURE_ESM_BUNDLER_WARN__: false
}
return args
})
},
Module versions
- “vue”: “^3.0.0”,
- “vue-i18n”: “^9.0.0”,
Issue Analytics
- State:
- Created 2 years ago
- Comments:12 (1 by maintainers)
Top Results From Across the Web
How to suppress Java compiler warnings for specific functions
Try to supress all the fall-through warning at the compiler level is a bad thing: as you've explained, the cases where you need...
Read more >Suppress code analysis warnings - .NET - Microsoft Learn
This article covers the various ways you can suppress warnings from code analysis when you build your .NET app. You can suppress code ......
Read more >Excluding warnings using @SuppressWarnings - IBM
Token Description Suppressed compiler option(s)
all to suppress all warnings All compiler options
cast to suppress warnings relative to cast operations Unnecessary cast or 'instance...
deprecation...
Read more >How to Suppress Warnings in R (With Examples) - Statology
You can use the following methods to suppress warnings in R: Method 1: Suppress Warnings on Specific Line suppressWarnings(one line of code).
Read more >How to Disable a Warning in C++
How to disable a warning across the 3 major C++ compilers with the same code.
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
Hi,
I don’t think this is fixed yet. Even if one sets all the necessary flags, on dev it will show the warning regardless, and this is because of the following:
The part with
typeof true === 'boolean'
is because the vue-i18n build script always replaces__FEATURE_ESM_BUNDLER_WARN__
withtrue
(in the source code). As displayed in the rollup.config.js (__FEATURE_ESM_BUNDLER_WARN__: true,
~line 238).@Unkrass I have been importing vue-i18n incorrectly, now It’s fixed!