Do the manifest.js and vonder.js files generated by webpack package report syntax errors in the IE browser environment?

as mentioned, the nuxt project built with npm run build does not display the page properly in all versions of the ie browser

the problem occurs in the vendor.js and manifest.js files packaged by webpack, as shown in the following figure:

related codes

nuxt.confing.js

build: {
    /*
    ** Run ESLint on save
    */
    //babel:{
    //presets:["babel-polyfill"],
    //},
    extend (config, { isDev, isClient, isServer }) {
      if (isDev && isClient) {
    config.entry["polyfill"] = ["babel-polyfill"]
        config.module.rules.push({
          enforce: "pre",
          test: /\.(js|vue)$/,
          loader: "eslint-loader",
          exclude: /(node_modules)/
        })
      }
      //if (isServer) {
      //  config.externals = [
      //    nodeExternals({
      //      whitelist:[/es6-promise|\.(?!(?:js|json)$).{1,5}$/i, /^vue-echarts/]
      //    })
      //  ]
      //}
    }
  }

I directly reported an error when I added babel-polyfill,es2015, result build to the babel configuration of nuxt.config.js. After using stage-0, the build vendor.js file became smaller, but it still could not be displayed normally in ie environment.
package.json is as follows:

{
  "name": "cpc",
  "version": "1.0.0",
  "description": "Nuxt.js project",
  "author": "",
  "private": true,
  "scripts": {
    "dev": "nuxt",
    "build": "nuxt build && nuxt start",
    "start": "PORT=8181 nuxt start",
    "generate": "nuxt generate",
    "lint": "eslint --ext .js,.vue --ignore-path .gitignore .",
    "precommit": "npm run lint"
  },
  "dependencies": {
    "@xkeshi/vue-qrcode": "^1.0.0",
    "axios": "^0.18.0",
    "babel-preset-es2015": "^6.24.1",
    "echart": "^0.1.3",
    "nuxt": "^1.0.0",
    "vue-awesome-swiper": "^3.1.3",
    "vue-echarts": "^3.0.9",
    "vue-style-loader": "^4.1.0"
  },
  "devDependencies": {
    "babel-eslint": "^8.2.1",
    "babel-polyfill": "^6.26.0",
    "babel-preset-es2015-ie": "^6.7.0",
    "babel-preset-stage-0": "^6.24.1",
    "eslint": "^4.15.0",
    "eslint-friendly-formatter": "^3.0.0",
    "eslint-loader": "^1.7.1",
    "eslint-plugin-vue": "^4.0.0",
    "webpack-node-externals": "^1.7.2"
  },
  "config": {
    "nuxt": {
      "host": "",
      "port": ""
    }
  }
}

I hope the god will give guidance

Nov.11,2021

take a look at the compatibility solutions on the Internet and find that it is still a problem of dependent files in node_modules. When webpack packages and parses, it will not parse the dependent files in node_modules. Vendor.js is also a script that caches project dependent files, so there is an incompatibility problem with earlier versions of browsers. The solution is obvious: 1. Overwrite dependent files that use es6 syntax. two Use other plug-ins. three. Write the dependent file as a direct reference to the component. As long as you don't parse to the es6 syntax in the cache file, there will be no compatibility issues.

Menu