Nuxt關閉Eslint代碼檢測

打開nuxt.config.js文件,註釋 extend

plugins: [
],
buildModules: [
],
modules: [
],
build: {
  // 代碼檢測
  // extend (config, ctx) {
   //   if (ctx.dev && ctx.isClient) {
   //     config.module.rules.push({
   //       enforce: 'pre',
   //       test: /\.(js|vue)$/,
   //       loader: 'eslint-loader',
   //       exclude: /(node_modules)/
   //     })
   //   }
  // }
}

注意:註釋完之後記得重新啓動項目

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章