vite-plugin-mock icon indicating copy to clipboard operation
vite-plugin-mock copied to clipboard

warning: "import.meta" is not available in the configured target environment ("es2015") and will be empty

Open lazebird opened this issue 3 years ago • 11 comments

warning: "import.meta" is not available in the configured target environment ("es2015") and will be empty async function resolveModule(p: string): Promise { target: 'es2015', 是否可以考虑提高版本来解决dev mock使用vite环境变量问题?

lazebird avatar Nov 12 '21 03:11 lazebird

there is a same 'warning',is any resolution?

priority3 avatar Aug 09 '22 03:08 priority3

there is a same 'warning', resolusion?

cxyi7 avatar Sep 12 '22 06:09 cxyi7

就是就是,不知道咋解决

KYX1234 avatar Dec 05 '22 02:12 KYX1234

在 vite.config.ts 中构建一个全局声明,再在 define 中引入 所需要的值就正常了

ItGarbager avatar Dec 17 '22 08:12 ItGarbager

encounter same problem

deltacat avatar Dec 20 '22 01:12 deltacat

It's 2023. Is there a solution?🤔

duanmw avatar Jan 03 '23 06:01 duanmw

It's 2023. Is there a solution?

uiboom avatar Feb 08 '23 07:02 uiboom

https://www.jianshu.com/p/8ce94077af2a

luocong2016 avatar Feb 16 '23 02:02 luocong2016

It's 2023. Is there a solution?

sincely avatar May 25 '23 08:05 sincely

It's 2024. Is there a solution?

Oct072021 avatar Apr 19 '24 13:04 Oct072021