question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Using standard with eslint-plugin-vue

See original GitHub issue

Hi folks, I’d like to suggest a snippet added to the docs describing how to use eslint-plugin-vue with standard, under the assumption that it’s a rather common linter, but specifically because its users don’t typically use it via eslint, but as its own binary.

I currently have it running as a separate npm script: one runs standard --plugin html '**/*.{js,vue}', and the other runs eslint 'src/**/*.vue' (with an .eslintrc that has the vue plugin in it) and that works fine, but there’s probably a way to consolidate. I haven’t done it, but figured someone here had, and waited to raise the suggestion of including it in the docs if others feel it’s warranted.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

5reactions
mesqueebcommented, May 22, 2018

Sorry @timwis I’m a bit confused. vue-cli 3 is a CLI, and I was more looking for a linter in VScode as a plugin perhaps. Or am I confusing things?

0reactions
vintproxcommented, May 4, 2019

@fancyboynet I guess it is related to Adonuxt template and/or AdonisJS starter .eslistrc.js configuration (I recognized it by // required to lint *.vue files comment). Adonuxt starter has error in configuration that seems pretty innocent:

  parser: 'babel-eslint',

but it should be replaced with

  parserOptions: {
    parser: 'babel-eslint'
  },

as noted here.

They also put html plugin as one that should lint vue files, but IMHO it’s weird: Vue SFCs are special, directives and scripts should be linted through eslint-plugin-vue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

@vue/eslint-config-standard - npm
Start using @vue/eslint-config-standard in your project by running `npm i @vue/eslint-config-standard`. There are 123 other projects in the ...
Read more >
User Guide | eslint-plugin-vue
In the Settings/Preferences dialog ( Cmd+, / Ctrl+Alt+S ), choose JavaScript under Languages and Frameworks and then choose ESLint under Code ...
Read more >
vuejs/eslint-config-standard - GitHub
ESLint Shareable Configs for JavaScript Standard Style in Vue.js Projects. JavaScript Style Guide - Standard Style. Usage.
Read more >
@vue/eslint-config-standard - npm package | Snyk
This config is specifically designed to be used by @vue/cli & create-vue setups and is not meant for outside use (it can be...
Read more >
Vue 2 - ESLint + Standard + Prettier - Stack Overflow
I wasn't able to find prettier anywhere in your config. Sure it's not just ESLint + Standard without prettier? – Royi Bernthal. Jul...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found