2-3 设置 webpack-dev-server的时候卡在了第一次执行npm run dev的地方了

来源:2-3 webpack-dev-server的配置和使用

qq_丶用笑容改变世界_0

2018-10-29 22:55

以下是报错信息


D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv-keywords\keywords\instanceof.js:52

    throw new Error('invalid "instanceof" keyword value ' + c);

    ^


Error: invalid "instanceof" keyword value Promise

    at getConstructor (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv-keywords\keywords\instanceof.js:52:11)

    at Ajv.compile (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv-keywords\keywords\instanceof.js:21:27)

    at Object.useCustomRule (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\compile\index.js:275:26)

    at Object.generate_custom [as code] (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\dotjs\custom.js:32:24)

    at Object.generate_validate [as validate] (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\dotjs\validate.js:347:35)

    at Object.generate_anyOf [as code] (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\dotjs\anyOf.js:34:27)

    at generate_validate (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\dotjs\validate.js:347:35)

    at localCompile (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\compile\index.js:87:22)

    at Ajv.compile (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\compile\index.js:56:13)

    at Ajv._compile (D:\wang\muke\vue-vueRouter-vuex-ssr\vue-todo-demo\node_modules\ajv\lib\ajv.js:358:27)


写回答 关注

3回答

  • 茉莉520清香
    2018-10-29 23:37:38
    已采纳

    webpack 的版本太高,你可以更换出现问题loader的版本或者降低webpack的版本

    qq_丶用笑...

    谢谢,已经解决了 webpack换成3.1了 所有的loader 都按照视频上的版本来了

    2018-11-02 23:30:44

    共 1 条回复 >

  • 慕少0106795
    2018-11-09 11:39:00
    把 webpack-dev-server版本改成2.9.1就好了
  • 慕少0106795
    2018-11-09 10:18:44

    lz,你的pageage.json截个图,我看下版本

Vue+Webpack打造todo应用

用前端最热门框架Vue+最火打包工具Webpack打造todo应用

84606 学习 · 787 问题

查看课程

相似问题