417511458 / jbone

jbone基于Spring Cloud框架开发,旨在为中小企业提供稳定的微服务解决方案,为开发人员提供基础开发骨架,jbone包含微服务中所有常用组件,例如注册中心、服务管理、服务监控、JVM监控、内存分析、调用链跟踪、API网关等等。业务功能包括系统权限的统一管理、单点登录、CMS、电商平台、工作流平台、支付平台等等。
http://jbone.cn/
Apache License 2.0
1k stars 513 forks source link

jbone-cms-admin前端构建时报component: () => import('@/view/single-page/home') #23

Open miguanxiong opened 5 years ago

miguanxiong commented 5 years ago

这个在ivew-admin中已经解决,在webapp目录添加 ![Uploading 图片.png…]()

wimigame commented 5 years ago

我添加了两个文件修改了一处代码可以尝试 (1) .eslintrc.js

module.exports = {
  root: true,
  'extends': [
    'plugin:vue/essential',
    '@vue/standard'
  ],
  rules: {
    // allow async-await
    'generator-star-spacing': 'off',
    // allow debugger during development
    'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
    'vue/no-parsing-error': [2, { 'x-invalid-end-tag': false }],
    'no-undef': 'off',
    'camelcase': 'off'
  },
  parserOptions: {
    parser: 'babel-eslint'
  }
}

(2) .babelrc

{
  "presets": [
    "@vue/app"
  ]
}

(3)修改了一处代码 webapp\vue.config.js

productionSourceMap: false 下面添加如下代码

css: {
    loaderOptions: { // 向 CSS 相关的 loader 传递选项
      less: {
        javascriptEnabled: true
      }
    }
  }

执行 npm install && npm run dev