Advertisement
Guest User

.eslintrc.js

a guest
May 18th, 2021
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. module.exports = {
  2.   root: true,
  3.   env: {
  4.     'node': true,
  5.     'browser': true,
  6.     'shared-node-browser': true,
  7.     'worker': true,
  8.     'serviceworker': true,
  9.     'commonjs': true,
  10.     'jquery': true,
  11.     'mongo': true,
  12.     'jasmine': true,
  13.     'mocha': true,
  14.     'es6': true
  15.   },
  16.   parserOptions: {
  17.     parser: '@typescript-eslint/parser'
  18.   },
  19.   extends: [
  20.     '@nuxtjs',
  21.     'plugin:nuxt/recommended'
  22.   ],
  23.   // add your custom rules here
  24.   rules: {
  25.     // `eslint` rules
  26.     'lines-between-class-members': [
  27.       1,
  28.       'always',
  29.       {
  30.         exceptAfterSingleLine: true
  31.       }
  32.     ],
  33.     'multiline-comment-style': 0,
  34.     'for-direction': 2,
  35.     'no-await-in-loop': 1,
  36.     'function-paren-newline': [
  37.       1,
  38.       'multiline'
  39.     ],
  40.     'no-compare-neg-zero': 2,
  41.     'no-cond-assign': [
  42.       2,
  43.       'except-parens'
  44.     ],
  45.     'no-console': 0,
  46.     'no-constant-condition': 1,
  47.     'no-control-regex': 1,
  48.     'no-debugger': 1,
  49.     'no-dupe-args': 2,
  50.     'no-dupe-keys': 2,
  51.     'no-duplicate-case': 2,
  52.     'no-empty': 1,
  53.     'no-empty-function': 1,
  54.     'no-empty-character-class': 1,
  55.     'no-ex-assign': 2,
  56.     'no-extra-boolean-cast': 2,
  57.     'no-extra-parens': [
  58.       1,
  59.       'all',
  60.       {
  61.         conditionalAssign: true,
  62.         returnAssign: true,
  63.         nestedBinaryExpressions: true,
  64.         ignoreJSX: 'all',
  65.         enforceForArrowConditionals: false
  66.       }
  67.     ],
  68.     'no-extra-semi': 2,
  69.     'no-func-assign': 2,
  70.     'no-inner-declarations': [
  71.       2,
  72.       'both'
  73.     ],
  74.     'no-invalid-regexp': 2,
  75.     'no-irregular-whitespace': [
  76.       2,
  77.       {
  78.         skipComments: true,
  79.         skipTemplates: true,
  80.         skipStrings: true,
  81.         skipRegExps: true
  82.       }
  83.     ],
  84.     'no-obj-calls': 2,
  85.     'no-prototype-builtins': 0,
  86.     'no-regex-spaces': 2,
  87.     'no-sparse-arrays': 2,
  88.     'no-template-curly-in-string': 1,
  89.     'no-unexpected-multiline': 2,
  90.     'no-unreachable': 2,
  91.     'no-unsafe-finally': 2,
  92.     'no-unsafe-negation': 2,
  93.     'use-isnan': 2,
  94.     'valid-jsdoc': [
  95.       1,
  96.       {
  97.         requireReturn: false,
  98.         prefer: {
  99.           arg: 'param',
  100.           argument: 'param',
  101.           returns: 'return'
  102.         },
  103.         preferType: {
  104.           Boolean: 'boolean',
  105.           Function: 'function',
  106.           Array: 'array',
  107.           Set: 'set',
  108.           Map: 'map',
  109.           Number: 'number',
  110.           Object: 'object',
  111.           String: 'string'
  112.         }
  113.       }
  114.     ],
  115.     'valid-typeof': [
  116.       2,
  117.       {
  118.         requireStringLiterals: true
  119.       }
  120.     ],
  121.     'accessor-pairs': 1,
  122.     'array-callback-return': [
  123.       2,
  124.       {
  125.         allowImplicit: true
  126.       }
  127.     ],
  128.     'block-scoped-var': 2,
  129.     'class-methods-use-this': 1,
  130.     'complexity': 0,
  131.     'consistent-return': 0,
  132.     'curly': [
  133.       1,
  134.       'all'
  135.     ],
  136.     'default-case': 2,
  137.     'dot-location': [
  138.       1,
  139.       'property'
  140.     ],
  141.     'dot-notation': 1,
  142.     'eqeqeq': [
  143.       2,
  144.       'always'
  145.     ],
  146.     'guard-for-in': 1,
  147.     'no-alert': 2,
  148.     'no-caller': 2,
  149.     'no-case-declarations': 2,
  150.     'no-div-regex': 1,
  151.     'no-else-return': [
  152.       1,
  153.       {
  154.         allowElseIf: true
  155.       }
  156.     ],
  157.     'no-empty-pattern': 2,
  158.     'no-eq-null': 2,
  159.     'no-eval': 2,
  160.     'no-extend-native': 0,
  161.     'no-extra-bind': 2,
  162.     'no-extra-label': 2,
  163.     'no-fallthrough': 2,
  164.     'no-floating-decimal': 2,
  165.     'no-global-assign': 2,
  166.     'no-implicit-coercion': 2,
  167.     'no-implicit-globals': 0,
  168.     'no-implied-eval': 2,
  169.     'no-invalid-this': 0,
  170.     'no-iterator': 2,
  171.     'no-labels': 2,
  172.     'no-lone-blocks': 2,
  173.     'no-loop-func': 2,
  174.     'no-magic-numbers': 0,
  175.     'no-multi-spaces': [
  176.       1,
  177.       {
  178.         ignoreEOLComments: true
  179.       }
  180.     ],
  181.     'no-multi-str': 2,
  182.     'no-new': 1,
  183.     'no-new-func': 2,
  184.     'no-new-wrappers': 2,
  185.     'no-octal': 2,
  186.     'no-octal-escape': 2,
  187.     'no-param-reassign': [
  188.       2,
  189.       {
  190.         props: false
  191.       }
  192.     ],
  193.     'no-proto': 0,
  194.     'no-redeclare': [
  195.       2,
  196.       {
  197.         builtinGlobals: true
  198.       }
  199.     ],
  200.     'no-restricted-properties': 0,
  201.     'no-return-assign': [
  202.       2,
  203.       'except-parens'
  204.     ],
  205.     'no-return-await': 1,
  206.     'no-script-url': 2,
  207.     'no-self-assign': [
  208.       2,
  209.       {
  210.         props: true
  211.       }
  212.     ],
  213.     'no-self-compare': 2,
  214.     'no-sequences': 2,
  215.     'no-throw-literal': 1,
  216.     'no-unmodified-loop-condition': 1,
  217.     'no-unused-expressions': [
  218.       2,
  219.       {
  220.         allowTaggedTemplates: true
  221.       }
  222.     ],
  223.     'no-unused-labels': 1,
  224.     'no-useless-call': 1,
  225.     'no-useless-concat': 1,
  226.     'no-useless-escape': 1,
  227.     'no-useless-return': 1,
  228.     'no-void': 1,
  229.     'no-warning-comments': 0,
  230.     'no-with': 2,
  231.     'prefer-promise-reject-errors': 0,
  232.     'radix': 2,
  233.     'require-await': 2,
  234.     'vars-on-top': 2,
  235.     'wrap-iife': [
  236.       2,
  237.       'inside',
  238.       {
  239.         functionPrototypeMethods: true
  240.       }
  241.     ],
  242.     'yoda': [
  243.       2,
  244.       'never',
  245.       {
  246.         onlyEquality: true
  247.       }
  248.     ],
  249.     'strict': 0,
  250.     'init-declarations': 0,
  251.     'no-catch-shadow': 2,
  252.     'no-delete-var': 2,
  253.     'no-label-var': 2,
  254.     'no-restricted-globals': 0,
  255.     'no-shadow': [
  256.       2,
  257.       {
  258.         builtinGlobals: true,
  259.         hoist: 'all',
  260.         allow: [
  261.           'name',
  262.           'event',
  263.           'e',
  264.           'error',
  265.           'context'
  266.         ]
  267.       }
  268.     ],
  269.     'no-shadow-restricted-names': 2,
  270.     'no-undef': 1,
  271.     'no-undef-init': 2,
  272.     'no-undefined': 0,
  273.     'no-unused-vars': [
  274.       1,
  275.       {
  276.         caughtErrors: 'all',
  277.         args: 'after-used',
  278.         ignoreRestSiblings: true
  279.       }
  280.     ],
  281.     'no-use-before-define': 2,
  282.     'callback-return': 0,
  283.     'global-require': 0,
  284.     'handle-callback-err': [
  285.       1,
  286.       '^.*(e|E)rr'
  287.     ],
  288.     'no-buffer-constructor': 2,
  289.     'no-mixed-requires': 0,
  290.     'no-new-require': 2,
  291.     'no-path-concat': 2,
  292.     'no-process-env': 0,
  293.     'no-process-exit': 0,
  294.     'no-restricted-modules': 0,
  295.     'no-sync': 2,
  296.     'array-bracket-newline': [
  297.       1,
  298.       {
  299.         multiline: true
  300.       }
  301.     ],
  302.     'array-bracket-spacing': [
  303.       1,
  304.       'never'
  305.     ],
  306.     'array-element-newline': 0,
  307.     'block-spacing': [
  308.       1,
  309.       'never'
  310.     ],
  311.     'brace-style': [
  312.       1,
  313.       'stroustrup',
  314.       {
  315.         allowSingleLine: true
  316.       }
  317.     ],
  318.     'camelcase': [
  319.       1,
  320.       {
  321.         properties: 'never',
  322.         ignoreDestructuring: true
  323.       }
  324.     ],
  325.     'capitalized-comments': 0,
  326.     'comma-dangle': [
  327.       1,
  328.       'never'
  329.     ],
  330.     'comma-spacing': [
  331.       1,
  332.       {
  333.         before: false,
  334.         after: true
  335.       }
  336.     ],
  337.     'comma-style': [
  338.       1,
  339.       'last'
  340.     ],
  341.     'computed-property-spacing': [
  342.       1,
  343.       'never'
  344.     ],
  345.     'consistent-this': [
  346.       1,
  347.       'that'
  348.     ],
  349.     'eol-last': 0,
  350.     'func-call-spacing': [
  351.       1,
  352.       'never'
  353.     ],
  354.     'func-name-matching': [
  355.       1,
  356.       'always'
  357.     ],
  358.     'func-names': [
  359.       1,
  360.       'as-needed'
  361.     ],
  362.     'func-style': [
  363.       1,
  364.       'declaration',
  365.       {
  366.         allowArrowFunctions: true
  367.       }
  368.     ],
  369.     'id-blacklist': 0,
  370.     'id-length': 0,
  371.     'id-match': 0,
  372.     'indent': [
  373.       1,
  374.       2,
  375.       {
  376.         VariableDeclarator: {
  377.           var: 2,
  378.           let: 2,
  379.           const: 3
  380.         },
  381.         FunctionExpression: {
  382.           body: 1,
  383.           parameters: 'first'
  384.         },
  385.         FunctionDeclaration: {
  386.           body: 1,
  387.           parameters: 'first'
  388.         },
  389.         MemberExpression: 1,
  390.         ArrayExpression: 1,
  391.         ObjectExpression: 1,
  392.         CallExpression: {
  393.           arguments: 1
  394.         },
  395.         SwitchCase: 1,
  396.         outerIIFEBody: 1
  397.       }
  398.     ],
  399.     'jsx-quotes': [
  400.       1,
  401.       'prefer-double'
  402.     ],
  403.     'key-spacing': [
  404.       1,
  405.       {
  406.         beforeColon: false,
  407.         afterColon: true,
  408.         mode: 'strict'
  409.       }
  410.     ],
  411.     'keyword-spacing': [
  412.       1,
  413.       {
  414.         before: true,
  415.         after: true
  416.       }
  417.     ],
  418.     'line-comment-position': 0,
  419.     'linebreak-style': 0,
  420.     'lines-around-comment': 0,
  421.     'max-depth': 0,
  422.     'max-len': [
  423.       0,
  424.       {
  425.         code: 85,
  426.         ignoreComments: false,
  427.         ignoreTrailingComments: true,
  428.         ignoreTemplateLiterals: true,
  429.         ignoreRegExpLiterals: true,
  430.         ignoreStrings: true,
  431.         ignoreUrls: true,
  432.         tabWidth: 2
  433.       }
  434.     ],
  435.     'max-lines': 0,
  436.     'max-nested-callbacks': [
  437.       1,
  438.       5
  439.     ],
  440.     'max-params': [
  441.       1,
  442.       5
  443.     ],
  444.     'max-statements': [
  445.       2,
  446.       50
  447.     ],
  448.     'max-statements-per-line': [
  449.       1,
  450.       {
  451.         max: 4
  452.       }
  453.     ],
  454.     'multiline-ternary': 0,
  455.     'new-cap': [
  456.       1,
  457.       {
  458.         newIsCap: true,
  459.         capIsNew: false,
  460.         properties: false
  461.       }
  462.     ],
  463.     'new-parens': 2,
  464.     'newline-per-chained-call': 0,
  465.     'no-array-constructor': 2,
  466.     'no-bitwise': [
  467.       1,
  468.       {
  469.         allow: [
  470.           '~',
  471.           '>>>',
  472.           '>>',
  473.           '<<'
  474.         ],
  475.         int32Hint: true
  476.       }
  477.     ],
  478.     'no-continue': 0,
  479.     'no-inline-comments': 0,
  480.     'no-lonely-if': 2,
  481.     'no-mixed-operators': 0,
  482.     'no-mixed-spaces-and-tabs': 2,
  483.     'no-multi-assign': 0,
  484.     'no-multiple-empty-lines': [
  485.       1,
  486.       {
  487.         max: 2
  488.       }
  489.     ],
  490.     'no-negated-condition': 0,
  491.     'no-nested-ternary': 2,
  492.     'no-new-object': 2,
  493.     'no-plusplus': 0,
  494.     'no-restricted-syntax': 0,
  495.     'no-tabs': 0,
  496.     'no-ternary': 0,
  497.     'no-trailing-spaces': [
  498.       1,
  499.       {
  500.         skipBlankLines: false,
  501.         ignoreComments: true
  502.       }
  503.     ],
  504.     'no-underscore-dangle': 0,
  505.     'no-unneeded-ternary': [
  506.       2,
  507.       {
  508.         defaultAssignment: true
  509.       }
  510.     ],
  511.     'no-whitespace-before-property': 1,
  512.     'nonblock-statement-body-position': [
  513.       1,
  514.       'beside'
  515.     ],
  516.     'object-curly-newline': [
  517.       1,
  518.       {
  519.         multiline: true,
  520.         consistent: true
  521.       }
  522.     ],
  523.     'object-curly-spacing': [
  524.       1,
  525.       'never'
  526.     ],
  527.     'object-property-newline': [
  528.       1,
  529.       {
  530.         allowAllPropertiesOnSameLine: true
  531.       }
  532.     ],
  533.     'one-var': 0,
  534.     'one-var-declaration-per-line': [
  535.       1,
  536.       'initializations'
  537.     ],
  538.     'operator-assignment': 0,
  539.     'operator-linebreak': [
  540.       1,
  541.       'after'
  542.     ],
  543.     'padded-blocks': [
  544.       1,
  545.       'never'
  546.     ],
  547.     'padding-line-between-statements': [
  548.       1,
  549.       {
  550.         blankLine: 'always',
  551.         prev: '*',
  552.         next: 'return'
  553.       },
  554.       {
  555.         blankLine: 'always',
  556.         prev: '*',
  557.         next: 'continue'
  558.       },
  559.       {
  560.         blankLine: 'always',
  561.         prev: '*',
  562.         next: 'break'
  563.       },
  564.       {
  565.         blankLine: 'always',
  566.         prev: '*',
  567.         next: 'function'
  568.       },
  569.       {
  570.         blankLine: 'always',
  571.         prev: 'function',
  572.         next: '*'
  573.       },
  574.       {
  575.         blankLine: 'always',
  576.         prev: '*',
  577.         next: 'for'
  578.       },
  579.       {
  580.         blankLine: 'always',
  581.         prev: 'for',
  582.         next: '*'
  583.       },
  584.       {
  585.         blankLine: 'always',
  586.         prev: [
  587.           'const',
  588.           'let',
  589.           'var'
  590.         ],
  591.         next: '*'
  592.       },
  593.       {
  594.         blankLine: 'any',
  595.         prev: [
  596.           'const',
  597.           'let',
  598.           'var'
  599.         ],
  600.         next: [
  601.           'const',
  602.           'let',
  603.           'var'
  604.         ]
  605.       },
  606.       {
  607.         blankLine: 'always',
  608.         prev: 'import',
  609.         next: '*'
  610.       },
  611.       {
  612.         blankLine: 'any',
  613.         prev: 'import',
  614.         next: 'import'
  615.       },
  616.       {
  617.         blankLine: 'always',
  618.         prev: 'for',
  619.         next: '*'
  620.       },
  621.       {
  622.         blankLine: 'always',
  623.         prev: 'directive',
  624.         next: '*'
  625.       },
  626.       {
  627.         blankLine: 'always',
  628.         prev: 'if',
  629.         next: '*'
  630.       },
  631.       {
  632.         blankLine: 'always',
  633.         prev: '*',
  634.         next: 'if'
  635.       },
  636.       {
  637.         blankLine: 'any',
  638.         prev: 'if',
  639.         next: 'if'
  640.       }
  641.     ],
  642.     'quote-props': [
  643.       1,
  644.       'consistent-as-needed',
  645.       {
  646.         numbers: true
  647.       }
  648.     ],
  649.     'quotes': [
  650.       1,
  651.       'single',
  652.       {
  653.         avoidEscape: true
  654.       }
  655.     ],
  656.     'require-jsdoc': [
  657.       1,
  658.       {
  659.         require: {
  660.           FunctionDeclaration: false,
  661.           MethodDefinition: false,
  662.           ClassDeclaration: false,
  663.           ArrowFunctionExpression: false,
  664.           FunctionExpression: false
  665.         }
  666.       }
  667.     ],
  668.     'semi': [
  669.       1,
  670.       'never'
  671.     ],
  672.     'semi-spacing': 0,
  673.     'semi-style': 0,
  674.     'sort-keys': 0,
  675.     'sort-vars': 0,
  676.     'space-before-blocks': [
  677.       1,
  678.       'always'
  679.     ],
  680.     'space-before-function-paren': [
  681.       1,
  682.       'always'
  683.     ],
  684.     'space-in-parens': [
  685.       1,
  686.       'never'
  687.     ],
  688.     'space-infix-ops': [
  689.       1,
  690.       {
  691.         int32Hint: true
  692.       }
  693.     ],
  694.     'space-unary-ops': [
  695.       1,
  696.       {
  697.         words: true,
  698.         nonwords: false
  699.       }
  700.     ],
  701.     'spaced-comment': [
  702.       1,
  703.       'always'
  704.     ],
  705.     'no-useless-constructor': 1,
  706.     'no-useless-rename': 1,
  707.     'no-var': 2,
  708.     'object-shorthand': [
  709.       1,
  710.       'always'
  711.     ],
  712.     'switch-colon-spacing': [
  713.       1,
  714.       {
  715.         after: true,
  716.         before: false
  717.       }
  718.     ],
  719.     'template-tag-spacing': [
  720.       1,
  721.       'never'
  722.     ],
  723.     'unicode-bom': [
  724.       2,
  725.       'never'
  726.     ],
  727.     'wrap-regex': 1,
  728.     'arrow-body-style': [
  729.       1,
  730.       'as-needed'
  731.     ],
  732.     'arrow-parens': [
  733.       1,
  734.       'as-needed'
  735.     ],
  736.     'arrow-spacing': [
  737.       1,
  738.       {
  739.         before: true,
  740.         after: true
  741.       }
  742.     ],
  743.     'constructor-super': 2,
  744.     'generator-star-spacing': [
  745.       1,
  746.       {
  747.         before: true,
  748.         after: false
  749.       }
  750.     ],
  751.     'no-class-assign': 2,
  752.     'no-confusing-arrow': [
  753.       1,
  754.       {
  755.         allowParens: true
  756.       }
  757.     ],
  758.     'no-const-assign': 2,
  759.     'no-dupe-class-members': 2,
  760.     'no-duplicate-imports': 1,
  761.     'no-new-symbol': 2,
  762.     'no-restricted-imports': 0,
  763.     'no-this-before-super': 2,
  764.     'no-useless-computed-key': 1,
  765.     'prefer-arrow-callback': 0,
  766.     'prefer-const': [
  767.       1,
  768.       {
  769.         destructuring: 'all'
  770.       }
  771.     ],
  772.     'prefer-destructuring': 0,
  773.     'prefer-numeric-literals': 0,
  774.     'prefer-rest-params': 1,
  775.     'prefer-spread': 1,
  776.     'prefer-template': 1,
  777.     'require-yield': 2,
  778.     'rest-spread-spacing': [
  779.       1,
  780.       'never'
  781.     ],
  782.     'sort-imports': 0,
  783.     'symbol-description': 1,
  784.     // @todo: Enable with `1` when value of null bug is resolved.
  785.     'template-curly-spacing': [
  786.       0,
  787.       'never'
  788.     ],
  789.     'yield-star-spacing': [
  790.       1,
  791.       'after'
  792.     ],
  793.     // `eslint-plugin-vue` rules
  794.     'vue/attribute-hyphenation': [
  795.       2,
  796.       'never'
  797.     ],
  798.     'vue/attributes-order': [
  799.       2,
  800.       {
  801.         order: [
  802.           'DEFINITION',
  803.           'LIST_RENDERING',
  804.           'CONDITIONALS',
  805.           'RENDER_MODIFIERS',
  806.           'GLOBAL',
  807.           'UNIQUE',
  808.           'TWO_WAY_BINDING',
  809.           'OTHER_DIRECTIVES',
  810.           'OTHER_ATTR',
  811.           'EVENTS',
  812.           'CONTENT'
  813.         ]
  814.       }
  815.     ],
  816.     'vue/component-name-in-template-casing': [
  817.       2,
  818.       'kebab-case',
  819.       {
  820.         ignores: []
  821.       }
  822.     ],
  823.     'vue/html-closing-bracket-newline': [
  824.       2,
  825.       {
  826.         singleline: 'never',
  827.         multiline: 'never'
  828.       }
  829.     ],
  830.     'vue/html-closing-bracket-spacing': [
  831.       'error',
  832.       {
  833.         startTag: 'never',
  834.         endTag: 'never',
  835.         selfClosingTag: 'never'
  836.       }
  837.     ],
  838.     'vue/html-end-tags': 2,
  839.     'vue/html-indent': [
  840.       1,
  841.       2
  842.     ],
  843.     'vue/html-quotes': [
  844.       2,
  845.       'double'
  846.     ],
  847.     'vue/html-self-closing': [
  848.       2,
  849.       {
  850.         html: {
  851.           void: 'never',
  852.           normal: 'always',
  853.           component: 'always'
  854.         },
  855.         svg: 'always',
  856.         math: 'always'
  857.       }
  858.     ],
  859.     'vue/max-attributes-per-line': [
  860.       2,
  861.       {
  862.         singleline: 1,
  863.         multiline: {
  864.           max: 1,
  865.           allowFirstLine: true
  866.         }
  867.       }
  868.     ],
  869.     'vue/multiline-html-element-content-newline': [
  870.       2,
  871.       {
  872.         ignores: [
  873.           'pre',
  874.           'textarea'
  875.         ]
  876.       }
  877.     ],
  878.     'vue/mustache-interpolation-spacing': [
  879.       2,
  880.       'always'
  881.     ],
  882.     'vue/name-property-casing': [
  883.       2,
  884.       'kebab-case'
  885.     ],
  886.     'vue/no-async-in-computed-properties': 2,
  887.     'vue/no-dupe-keys': [
  888.       2,
  889.       {
  890.         groups: []
  891.       }
  892.     ],
  893.     'vue/no-duplicate-attributes': [
  894.       2,
  895.       {
  896.         allowCoexistClass: true,
  897.         allowCoexistStyle: true
  898.       }
  899.     ],
  900.     'vue/no-multi-spaces': [
  901.       2,
  902.       {
  903.         ignoreProperties: true
  904.       }
  905.     ],
  906.     'vue/no-parsing-error': [
  907.       2,
  908.       {
  909.         'abrupt-closing-of-empty-comment': true,
  910.         'absence-of-digits-in-numeric-character-reference': true,
  911.         'cdata-in-html-content': true,
  912.         'character-reference-outside-unicode-range': true,
  913.         'control-character-in-input-stream': true,
  914.         'control-character-reference': true,
  915.         'eof-before-tag-name': true,
  916.         'eof-in-cdata': true,
  917.         'eof-in-comment': true,
  918.         'eof-in-tag': true,
  919.         'incorrectly-closed-comment': true,
  920.         'incorrectly-opened-comment': true,
  921.         'invalid-first-character-of-tag-name': true,
  922.         'missing-attribute-value': true,
  923.         'missing-end-tag-name': true,
  924.         'missing-semicolon-after-character-reference': true,
  925.         'missing-whitespace-between-attributes': true,
  926.         'nested-comment': true,
  927.         'noncharacter-character-reference': true,
  928.         'noncharacter-in-input-stream': true,
  929.         'null-character-reference': true,
  930.         'surrogate-character-reference': true,
  931.         'surrogate-in-input-stream': true,
  932.         'unexpected-character-in-attribute-name': true,
  933.         'unexpected-character-in-unquoted-attribute-value': true,
  934.         'unexpected-equals-sign-before-attribute-name': true,
  935.         'unexpected-null-character': true,
  936.         'unexpected-question-mark-instead-of-tag-name': true,
  937.         'unexpected-solidus-in-tag': true,
  938.         'unknown-named-character-reference': true,
  939.         'end-tag-with-attributes': true,
  940.         'duplicate-attribute': true,
  941.         'end-tag-with-trailing-solidus': true,
  942.         'non-void-html-element-start-tag-with-trailing-solidus': false,
  943.         'x-invalid-end-tag': true,
  944.         'x-invalid-namespace': true
  945.       }
  946.     ],
  947.     'vue/no-reserved-keys': [
  948.       2,
  949.       {
  950.         reserved: [],
  951.         groups: []
  952.       }
  953.     ],
  954.     'vue/no-shared-component-data': 2,
  955.     'vue/no-side-effects-in-computed-properties': 1,
  956.     'vue/no-spaces-around-equal-signs-in-attribute': 2,
  957.     'vue/no-template-key': 2,
  958.     'vue/no-template-shadow': 2,
  959.     'vue/no-textarea-mustache': 2,
  960.     'vue/no-unused-components': [
  961.       1,
  962.       {
  963.         ignoreWhenBindingPresent: false
  964.       }
  965.     ],
  966.     'vue/no-unused-vars': 1,
  967.     'vue/no-use-v-if-with-v-for': [
  968.       2,
  969.       {
  970.         allowUsingIterationVar: true
  971.       }
  972.     ],
  973.     'vue/no-v-html': 0,
  974.     'vue/order-in-components': [
  975.       2,
  976.       {
  977.         order: [
  978.           'el',
  979.           'name',
  980.           'parent',
  981.           'layout',
  982.           'key',
  983.           'functional',
  984.           'loading',
  985.           [
  986.             'delimiters',
  987.             'comments'
  988.           ],
  989.           [
  990.             'components',
  991.             'directives',
  992.             'filters'
  993.           ],
  994.           'extends',
  995.           'mixins',
  996.           'inheritAttrs',
  997.           'model',
  998.           [
  999.             'props',
  1000.             'propsData'
  1001.           ],
  1002.           'watchQuery',
  1003.           'asyncData',
  1004.           'fetch',
  1005.           'data',
  1006.           'computed',
  1007.           'watch',
  1008.           'channels',
  1009.           'validations',
  1010.           'head',
  1011.           'middleware',
  1012.           'validate',
  1013.           'beforeRouteEnter',
  1014.           'beforeRouteUpdate',
  1015.           'beforeRouteLeave',
  1016.           'beforeCreate',
  1017.           'created',
  1018.           'beforeMount',
  1019.           'mounted',
  1020.           'beforeUpdate',
  1021.           'updated',
  1022.           'activated',
  1023.           'deactivated',
  1024.           'beforeDestroy',
  1025.           'destroyed',
  1026.           'methods',
  1027.           [
  1028.             'template',
  1029.             'render'
  1030.           ],
  1031.           'renderError',
  1032.           'scrollToTop',
  1033.           'transition'
  1034.         ]
  1035.       }
  1036.     ],
  1037.     'vue/prop-name-casing': [
  1038.       2,
  1039.       'camelCase'
  1040.     ],
  1041.     'vue/require-component-is': 2,
  1042.     'vue/require-default-prop': 2,
  1043.     'vue/require-prop-type-constructor': 2,
  1044.     'vue/require-prop-types': 2,
  1045.     'vue/require-render-return': 2,
  1046.     'vue/require-v-for-key': 2,
  1047.     'vue/require-valid-default-prop': 2,
  1048.     'vue/return-in-computed-property': [
  1049.       2,
  1050.       {
  1051.         treatUndefinedAsUnspecified: false
  1052.       }
  1053.     ],
  1054.     'vue/script-indent': [
  1055.       1,
  1056.       2,
  1057.       {
  1058.         baseIndent: 1,
  1059.         switchCase: 0,
  1060.         ignores: []
  1061.       }
  1062.     ],
  1063.     'vue/singleline-html-element-content-newline': [
  1064.       2,
  1065.       {
  1066.         ignoreWhenNoAttributes: false,
  1067.         ignores: [
  1068.           'pre',
  1069.           'textarea'
  1070.         ]
  1071.       }
  1072.     ],
  1073.     'vue/this-in-template': [
  1074.       2,
  1075.       'never'
  1076.     ],
  1077.     'vue/use-v-on-exact': 1,
  1078.     'vue/v-bind-style': [
  1079.       1,
  1080.       'shorthand'
  1081.     ],
  1082.     'vue/v-on-style': [
  1083.       1,
  1084.       'shorthand'
  1085.     ],
  1086.     'vue/valid-template-root': 2,
  1087.     'vue/valid-v-bind': 2,
  1088.     'vue/valid-v-cloak': 2,
  1089.     'vue/valid-v-else-if': 2,
  1090.     'vue/valid-v-else': 2,
  1091.     'vue/valid-v-for': 2,
  1092.     'vue/valid-v-html': 2,
  1093.     'vue/valid-v-if': 2,
  1094.     'vue/valid-v-model': 2,
  1095.     'vue/valid-v-on': 2,
  1096.     'vue/valid-v-once': 2,
  1097.     'vue/valid-v-pre': 2,
  1098.     'vue/valid-v-show': 2,
  1099.     'vue/valid-v-text': 2,
  1100.     'vue/v-on-function-call': [
  1101.       2,
  1102.       'never'
  1103.     ],
  1104.     'vue/require-direct-export': 0,
  1105.     'vue/no-boolean-default': 0,
  1106.     'vue/match-component-file-name': 0,
  1107.     'vue/array-bracket-spacing': [
  1108.       1,
  1109.       'never'
  1110.     ],
  1111.     'vue/eqeqeq': [
  1112.       2,
  1113.       'always'
  1114.     ],
  1115.     'vue/key-spacing': [
  1116.       1,
  1117.       {
  1118.         beforeColon: false,
  1119.         afterColon: true,
  1120.         mode: 'strict'
  1121.       }
  1122.     ],
  1123.     'vue/object-curly-spacing': [
  1124.       1,
  1125.       'never'
  1126.     ],
  1127.     'vue/space-infix-ops': [
  1128.       1,
  1129.       {
  1130.         int32Hint: true
  1131.       }
  1132.     ],
  1133.     'vue/space-unary-ops': [
  1134.       1,
  1135.       {
  1136.         words: true,
  1137.         nonwords: false
  1138.       }
  1139.     ],
  1140.     'vue/no-restricted-syntax': 0,
  1141.     'vue/arrow-spacing': [
  1142.       1,
  1143.       {
  1144.         before: true,
  1145.         after: true
  1146.       }
  1147.     ],
  1148.     'vue/block-spacing': [
  1149.       1,
  1150.       'never'
  1151.     ],
  1152.     'vue/brace-style': [
  1153.       1,
  1154.       'stroustrup',
  1155.       {
  1156.         allowSingleLine: true
  1157.       }
  1158.     ],
  1159.     'vue/camelcase': [
  1160.       1,
  1161.       {
  1162.         properties: 'never',
  1163.         ignoreDestructuring: true
  1164.       }
  1165.     ],
  1166.     'vue/comma-dangle': [
  1167.       1,
  1168.       'never'
  1169.     ],
  1170.     'vue/padding-line-between-blocks': [
  1171.       1,
  1172.       'always'
  1173.     ],
  1174.     'vue/component-definition-name-casing': [2, 'kebab-case'],
  1175.     // `eslint-plugin-nuxt` rules
  1176.     'nuxt/no-cjs-in-config': 1,
  1177.     'nuxt/no-env-in-context': 2,
  1178.     'nuxt/no-env-in-hooks': 2,
  1179.     'nuxt/no-globals-in-created': 2,
  1180.     'nuxt/no-this-in-fetch-data': 2,
  1181.     'nuxt/no-timing-in-fetch-data': 2,
  1182.     // `eslint-plugin-import` rules
  1183.     'import/order': 2,
  1184.     'import/first': 2,
  1185.     'import/no-mutable-exports': 2,
  1186.     'import/no-unresolved': 0,
  1187.     'import/exports-last': 2,
  1188.     // `eslint-plugin-unicorn` rules
  1189.     'unicorn/error-message': 2,
  1190.     'unicorn/escape-case': 2,
  1191.     'unicorn/explicit-length-check': 0,
  1192.     'unicorn/new-for-builtins': 1,
  1193.     'unicorn/no-array-instanceof': 2,
  1194.     'unicorn/no-new-buffer': 2,
  1195.     'unicorn/throw-new-error': 2
  1196.   },
  1197.   overrides: [
  1198.     {
  1199.       files: ['*.vue'],
  1200.       rules: {
  1201.         indent: 'off'
  1202.       }
  1203.     }
  1204.   ]
  1205. }
  1206.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement