Skip to content

Instantly share code, notes, and snippets.

@acacha
Last active November 13, 2019 17:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save acacha/31f136c44fada96af6e46f3d103d267a to your computer and use it in GitHub Desktop.
Save acacha/31f136c44fada96af6e46f3d103d267a to your computer and use it in GitHub Desktop.
LINTING

Javascript

ESLINT

Com sap quina configuració aplicar: fitxer .eslintrc.js a la carpeta o carpetes pare (fins arribar a una que posi root: true)

Configuració .eslintrc.js (https://eslint.org/docs/user-guide/configuring). Exemple Nuxt:

module.exports = {
  root: true,
  env: {
    browser: true,
    node: true
  },
  parserOptions: {
    parser: 'babel-eslint'
  },
  extends: [
    '@nuxtjs',
    'plugin:nuxt/recommended'
  ],
  // add your custom rules here
  rules: {
  }
}

Nuxt

https://nuxtjs.org/guide/development-tools/#eslint-and-prettier

Recomanacions:

PHPSTORM

-https://www.jetbrains.com/help/phpstorm/eslint.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment