美文网首页
iview框架,npm run dev报错:error in .

iview框架,npm run dev报错:error in .

作者: 土豆特别想爬山 | 来源:发表于2019-04-10 15:26 被阅读0次

    使用iview框架,npm run dev报错:

    error in ./src/index.less

    Module build failed (from ./node_modules/less-loader/dist/cjs.js):

    // https://github.com/ant-design/ant-motion/issues/44

    .bezierEasingMixin();

    ^

    Inline JavaScript is not enabled. Is it set in your options?

          in D:\CODE\gdfront\node_modules\iview\src\styles\color\bezierEasing.less (

    line 110, column 0)

    @ ./src/index.less 4:14-216 14:3-18:5 15:22-224

    @ ./src/main.js

    @ multi (webpack)-dev-server/client?http://localhost:8081/sockjs-node (webpack)

    /hot/dev-server.js ./src/main.js

    报错

    解决方法,参考https://github.com/ant-design/ant-motion/issues/44:
    找到vue.config.js文件,没有vue.config.js的话新建,添加下面代码:

    module.exports = { css: { loaderOptions: { less: { javascriptEnabled: true, } } },}

    相关文章

      网友评论

          本文标题:iview框架,npm run dev报错:error in .

          本文链接:https://www.haomeiwen.com/subject/faoniqtx.html