1. 程式人生 > >Use // eslint-disable-next-line to ignore the next line.解決辦法

Use // eslint-disable-next-line to ignore the next line.解決辦法

npm start 啟動服務的時候,出現了一下報錯:

You may use special comments to disable some warnings.
Use // eslint-disable-next-line to ignore the next line.
Use /* eslint-disable */ to ignore all warnings in a file.

都是因為開啟了eslint 編碼規範檢查

解決辦法:

1.找到webpack.base.conf.js檔案:

找到這行程式碼註釋掉就可以了!!

 //...(config.dev.useEslint ? [createLintingRule()] : []),

示例如下:

 2.npm start 執行之後就正常運行了!!