[Vuejs]-Use the latest vue-eslint-parser – encore

0πŸ‘

βœ…

it’s because Encore force parser option to babel-eslint and it’s not compatible with eslint-plugin-vue.

As a workaround you can use the following code to let Encore/ESLint lint your .vue files:

Encore
  .enableEslintLoader(options => {
      delete options.parser;
  })
  .configureLoaderRule('eslint', loader => {
      loader.test = /\.(jsx?|vue)$/;
  })

All credits goes to Kocal at Github: https://github.com/symfony/webpack-encore/issues/656

Leave a comment