Skip to content

Commit

Permalink
Updated typescript rules.
Browse files Browse the repository at this point in the history
  • Loading branch information
moonstar-x committed Jul 20, 2023
1 parent 08c680f commit 80ac0ae
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 5 deletions.
9 changes: 7 additions & 2 deletions es6.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,12 @@ module.exports = {
'no-undef': 'error',
'no-undefined': 'off',
'no-unused-vars': 'error',
'no-use-before-define': ['error', 'nofunc'],
'no-use-before-define': ['error', {
'functions': true,
'classes': false,
'variables': true,
'allowNamedExports': false
}],

// ES6
'arrow-parens': ['error', 'always'],
Expand Down Expand Up @@ -149,7 +154,7 @@ module.exports = {
'skipComments': true,
'skipBlankLines': true
}],
'max-params': ['warn', 3],
'max-params': ['warn', 4],
'max-statements-per-line': 'error',
'max-statements': ['error', 30, {
'ignoreTopLevelFunctions': true
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eslint-config-greencoast",
"version": "0.0.3",
"version": "0.0.4",
"description": "A shareable ESLint config used by Greencoast Studios.",
"repository": {
"type": "git",
Expand Down
18 changes: 17 additions & 1 deletion typescript.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,22 @@ module.exports = {
'greencoast/es6'
],
rules: {
'@typescript-eslint/no-non-null-assertion': 'off'
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-unsafe-declaration-merging': 'off',

'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': ['error', {
'functions': true,
'classes': false,
'variables': true,
'allowNamedExports': false,
'enums': true,
'typedefs': true,
'ignoreTypeReferences': true
}],
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': 'error',
'no-redeclare': 'off',
'@typescript-eslint/no-redeclare': 'error'
}
};

0 comments on commit 80ac0ae

Please sign in to comment.