iview / iview-project

This project is build for Vue.js 2 + vue-router + webpack2 + iView 3
MIT License
839 stars 389 forks source link

npm run init np , however npm run dev error. #55

Closed HappyColour closed 4 years ago

HappyColour commented 6 years ago

iview-project@2.1.0 dev /Users/zeus/Heaven/iview-project-forVue/iview-project webpack-dev-server --content-base ./ --open --inline --hot --compress --history-api-fallback --config webpack.dev.config.js

/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv-keywords/keywords/instanceof.js:52 throw new Error('invalid "instanceof" keyword value ' + c); ^

Error: invalid "instanceof" keyword value Promise at getConstructor (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv-keywords/keywords/instanceof.js:52:11) at Ajv.compile (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv-keywords/keywords/instanceof.js:21:27) at Object.useCustomRule (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/compile/index.js:289:26) at Object.generate_custom [as code] (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/dotjs/custom.js:32:24) at Object.generate_validate [as validate] (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/dotjs/validate.js:229:37) at Object.generate_anyOf [as code] (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/dotjs/anyOf.js:35:27) at generate_validate (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/dotjs/validate.js:229:37) at localCompile (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/compile/index.js:99:22) at Ajv.compile (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/compile/index.js:67:13) at _compile (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/ajv.js:328:29) at Ajv.compile (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/ajv/lib/ajv.js:114:34) at validateObject (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/webpack/lib/validateSchema.js:36:23) at validateSchema (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/webpack/lib/validateSchema.js:31:10) at processConfiguredOptions (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/webpack-cli/bin/convert-argv.js:156:48) at module.exports (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/webpack-cli/bin/convert-argv.js:150:10) at Object. (/Users/zeus/Heaven/iview-project-forVue/iview-project/node_modules/webpack-dev-server/bin/webpack-dev-server.js:234:54)

HappyColour commented 6 years ago

Oh,I have solved this pb, because my "webpack-dev-server" version is too hight , u can use the version "2.9.7" .

smoquet commented 5 years ago

thank you HappyColour, saved my day!!!