更多ruoyi-nbcio功能请看演示系统
gitee源代码地址
演示地址:RuoYi-Nbcio后台管理系统
ruoyi-nbcio 前端编译出现下面问题
98% after emitting CopyPlugin
WARNING Compiled with 1 warning 10:46:08
warning in ./src/components/HeaderNotice/DynamicNotice.vue?vue&type=script&lang=js&
Critical dependency: the request of a dependency is an expression
App running at:
- Local: http://localhost:9666/
- Network: http://172.18.3.56:9666/
主要是下面语句问题
return () => import(`@/views/${this.path}.vue`)
应该是跟webpack版本相关,可能的bug吧,webpack4中动态import不支持变量方式。
以后版本升级可以解决,目前先临时用下面方法解决吧。
computed: { comp: function () { if(!this.path){ return null; } //return () => import(`@/views/${this.path}.vue`) //去掉这个编译警告Critical dependency: the request of a dependency is an expression return () => Promise.resolve(require(`@/views/${this.path}.vue`).default) }