TypeError: validateSchema is not a function
来源:3-4 npm和webpack的初始化
慕盖茨501769
2018-10-24
输这句话的时候 webpack ./src/page/index/index.js ./dist/app.js不成功显示
TypeError: validateSchema is not a function
at processConfiguredOptions (/Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/webpack-cli/bin/convert-argv.js:156:48)
at module.exports (/Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/webpack-cli/bin/convert-argv.js:150:10)
at yargs.parse (/Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/webpack-cli/bin/cli.js:241:39)
at Object.parse (/Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/yargs/yargs.js:563:18)
at /Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/webpack-cli/bin/cli.js:219:8
at Object. (/Users/apple/Desktop/mmall/doc/mmall-fe/node_modules/webpack-cli/bin/cli.js:538:3)
at Module._compile (internal/modules/cjs/loader.js:688:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
at Function.Module._load (internal/modules/cjs/loader.js:529:3)
at Module.require (internal/modules/cjs/loader.js:636:17)
at require (internal/modules/cjs/helpers.js:20:18)
at module.exports.filename (/usr/local/lib/node_modules/webpack-cli/node_modules/import-local/index.js:16:66)
at /usr/local/lib/node_modules/webpack-cli/bin/cli.js:13:6
at Object. (/usr/local/lib/node_modules/webpack-cli/bin/cli.js:538:3)
at Module._compile (internal/modules/cjs/loader.js:688:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
at Function.Module._load (internal/modules/cjs/loader.js:529:3)
at Module.require (internal/modules/cjs/loader.js:636:17)
at require (internal/modules/cjs/helpers.js:20:18)
at Object. (/usr/local/lib/node_modules/webpack/bin/webpack.js:155:2)
at Module._compile (internal/modules/cjs/loader.js:688:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)
at Function.Module._load (internal/modules/cjs/loader.js:529:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:741:12)
1回答
-
mid_one
2018-10-24
运行的时候执行webpack就行了,webpack.config.js配置了entry入口文件和output出口的
另外提示你了validateSchema不是函数类型, 你是用了webpack4吗?这里全都是webpack报的错并不是你程序的错
132018-10-25
相似问题