ERROR in chunk chunk-03b6 static/js/chunk-03b6.0c3f4b7a.js C:\Users\sun\Documents\Tencent Files\779959311\FileRecv\vue-admin\vue-admin\node_modules\babel-loader\lib\index.js!C:\Users\sun\Documents\Tencent Files\779959311\FileRecv\vue-admin\vue-admin\src\api\userTable.js 96b10d4b12ee7b5260b9ae8d337b3b14 Unexpected token (9:15) | // 创建axios实例 | var service = __WEBPACK_MODULE_REFERENCE__1_64656661756c74__.create({ | baseURL: http://localhost:8085, // api 的 base_url | timeout: 5000 // 请求超时时间 | }); Build failed with errors.
时间: 2023-07-12 17:02:41 浏览: 53
这个错误提示是因为在`userTable.js`文件的第9行第15列有一个意外的标记,可能是由于您的代码中有一些语法错误导致的。您可以尝试按照以下步骤来解决这个问题:
1. 检查`userTable.js`文件中的代码,看看是否有拼写错误、缺少括号、分号等语法问题。
2. 确认您的代码是否使用了ES6的语法,例如箭头函数、模板字符串等。如果是的话,您需要确保您的代码能够被Babel正确转换。
3. 检查`userTable.js`文件中的第9行第15列的代码,看看是否有遗漏或多余的符号。如果有,您可以尝试删除或添加这些符号以解决问题。
希望这些提示可以帮助您解决问题。如果问题仍然存在,请提供更多的信息和代码段,以便我更好地帮助您。
相关问题
e[d] is not a function TypeError: e[d] is not a function at i (http://localhost:8080/public/templateVue/js/chunk_common_1_2.js:1:131077) at ./node_modules/core-js/modules/es.string.split.js (http://localhost:8080/static/js/index.js:2412:111) at __webpack_require__ (http://localhost:8080/static/js/index.js:2874:33) at fn (http://localhost:8080/static/js/index.js:3074:21) at eval (webpack-internal:///./node_modules/element-ui/lib/utils/popup/popup-manager.js:4:1) at ./node_modules/element-ui/lib/utils/popup/popup-manager.js (http://localhost:8080/static/js/index.js:169:1) at __webpack_require__ (http://localhost:8080/static/js/index.js:2874:33) at fn (http://localhost:8080/static/js/index.js:3074:21) at eval (webpack-internal:///./node_modules/element-ui/lib/utils/popup/index.js:10:21) at ./node_modules/element-ui/lib/utils/popup/index.js (http://localhost:8080/static/js/index.js:158:1)
这个错误通常发生在JavaScript代码中,表示某个变量不是一个函数,无法被调用。根据错误信息,我们可以看到错误发生在 "es.string.split.js" 文件中的第 2412 行,并且在 "popup-manager.js" 文件中的第 4 行和 "popup/index.js" 文件中的第 10 行也有相关的调用。
要解决这个问题,你可以按照以下步骤进行排查:
1. 检查你的代码中对函数的调用是否正确。确保传递给函数的参数是正确的,并且函数名称拼写正确。
2. 检查相关文件是否正确导入。确保文件路径和名称是正确的,并且文件确实存在。
3. 检查相关文件中的代码是否有语法错误或逻辑错误。这些错误可能导致函数无法正确定义或导入。
如果你能提供更多的代码或错误信息,我可以帮你更具体地分析问题并提供更准确的解决方案。
Cannot read properties of undefined (reading 'prototype') TypeError: Cannot read properties of undefined (reading 'prototype') at eval (webpack-internal:///./node_modules/element-ui/lib/utils/dom.js:22:30) at ./node_modules/element-ui/lib/utils/dom.js (http://localhost:8080/js/chunk-vendors.js:1410:1) at __webpack_require__ (http://localhost:8080/js/app.js:198:33) at fn (http://localhost:8080/js/app.js:431:21) at eval (webpack-internal:///./node_modules/element-ui/lib/utils/popup/popup-manager.js:7:12) at ./node_modules/element-ui/lib/utils/popup/popup-manager.js (http://localhost:8080/js/chunk-vendors.js:1454:1) at __webpack_require__ (http://localhost:8080/js/app.js:198:33) at fn (http://localhost:8080/js/app.js:431:21) at eval (webpack-internal:///./node_modules/element-ui/lib/utils/popup/index.js:9:21) at ./node_modules/element-ui/lib/utils/popup/index.js (http://localhost:8080/js/chunk-vendors.js:1443:1)这么解决这个问题
这个错误通常是由于您使用的 Element UI 的某个模块或组件没有正确导入或安装所致。您可以重新安装 Element UI,或者检查您的代码中是否有错误的导入语句或缺失的依赖项。如果您使用的是 Vue CLI,可以尝试在 main.js 中正确导入 Element UI:
```javascript
import { createApp } from 'vue'
import App from './App.vue'
import ElementPlus from 'element-plus' // 导入 Element UI
import 'element-plus/dist/index.css' // 导入 Element UI 样式
createApp(App)
.use(ElementPlus) // 使用 Element UI
.mount('#app')
```
如果您已经正确导入 Element UI 并安装了所有依赖项,您还可以尝试升级 Element UI 到最新版本。如果这些方法都不起作用,您可以尝试使用其他 UI 框架或查看 Element UI 的文档或社区以获取更多帮助。