Skip to content

Commit

Permalink
Add ESLINT on save
Browse files Browse the repository at this point in the history
  • Loading branch information
atinux committed Feb 11, 2017
1 parent 03a0a0c commit 8719d45
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion template/nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,23 @@ module.exports = {
/*
** Customize the progress-bar color
*/
loading: { color: '#3B8070' }
loading: { color: '#3B8070' },
/*
** Build configuration
*/
build: {
/*
** Run ESLINT on save
*/
extend (config, { isClient }) {
if (isClient) {
config.module.rules.push({
enforce: 'pre',
test: /\.(js|vue)$/,
loader: 'eslint-loader',
exclude: /(node_modules)/
})
}
}
}
}

0 comments on commit 8719d45

Please sign in to comment.