• Register
Welcome to Kodlogs, programming questions and answer website.
0 votes


I am getting this error can someone help:

Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.

 - configuration has an unknown property 'jshint'. These properties are valid:

   object { amd?, bail?, cache?, context?, dependencies?, devServer?, devtool?, entry, externals?, loader?, module?, name?, node?, output?, parallelism?, performance?, plugins?, profile?, recordsInputPath?, recordsOutputPath?, recordsPath?, resolve?, resolveLoader?, stats?, target?, watch?, watchOptions? }

   For typos: please correct them.

   For loader options: webpack 2 no longer allows custom properties in configuration.

     Loaders should be updated to allow passing options via loader options in module.rules.

     Until loaders are updated one can use the LoaderOptionsPlugin to pass these options to the loader:

     plugins: [

       new webpack.LoaderOptionsPlugin({

         // test: /\.xxx$/, // may apply this only for some modules

         options: {

           jshint: ...




by (1.6k points)  
edited by

1 Answer

0 votes

Troubleshooting issue:

step1: You need to do npm install webpack-cli -g

step2: Some changes to webpackconfig.js would be as following:


var path = require('path');

module.exports = {

entry: './main.ts',

resolve: {

extensions: ['.webpack.js', '.web.js', '.ts', '.js']


module: {

rules: [

{ test: /.ts$/, loader: 'ts-loader' }



output: {

filename: 'bundle.js',

path: path.resolve(__dirname, 'dist')





so npm install webpack-cli -g and alter to webpackconfig.js will sort out the issue.

by (5.3k points)