Error starting project after babel-loader processing vue-echarts-v3

vue-echarts-v3, is used in the project because there is ES6 code in it after packaging, so add vue-echarts-v3 to the processing scope of babel-loader.

in webpack.base.conf.js:

{
    test: /\.js$/,
    loader: "babel-loader",
    options:{
        plugins: ["syntax-dynamic-import"]
    },
    include: [resolve("src"), resolve("test"), resolve("node_modules/vue-echarts-v3"), resolve("node_modules/webpack-dev-server")]
}

.babelrc configuration:

{
    "presets": [
        ["env", {
            "modules": false,
            "targets": {
                "browsers": ["> 1%", "last 2 versions", "not ie <= 8"],
                "node": "current"
            }
        }],
        "stage-2"
    ],
    "plugins": [
        "transform-vue-jsx", "transform-runtime"
    ]
}

then npm start sends a warning:
warning in. / node_modules/vue-echarts-v3/src/wrapper.js
"export "default" (imported as" _") was not found in "lodash"
clipboard.png

other pages also introduce lodash, but why is this a problem in vue-echarts-v3 "s wrapper.js? If babel-loader is not allowed to deal with vue-echarts-v3, there will be no problem

Mar.22,2021

is there .babelrc ? How is babel-loader' configured in the webpack.*.conf.js file?

Menu