Skip to content

Commit

Permalink
Allow parameters to use PascalCase (#264)
Browse files Browse the repository at this point in the history
Parameters can now use PascaleCase. This can be useful in cases where a
class constructor is being passed as a parameter.
  • Loading branch information
Gudahtt committed Dec 12, 2022
1 parent 732041d commit d1e6352
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/typescript/rules-snapshot.json
Expand Up @@ -44,6 +44,11 @@
"selector": "variable",
"format": ["camelCase", "UPPER_CASE", "PascalCase"],
"leadingUnderscore": "allow"
},
{
"selector": "parameter",
"format": ["camelCase", "PascalCase"],
"leadingUnderscore": "allow"
}
],
"@typescript-eslint/no-array-constructor": "error",
Expand Down
5 changes: 5 additions & 0 deletions packages/typescript/src/index.js
Expand Up @@ -111,6 +111,11 @@ module.exports = {
format: ['camelCase', 'UPPER_CASE', 'PascalCase'],
leadingUnderscore: 'allow',
},
{
selector: 'parameter',
format: ['camelCase', 'PascalCase'],
leadingUnderscore: 'allow',
},
],
'@typescript-eslint/no-meaningless-void-operator': 'error',
'@typescript-eslint/no-unnecessary-boolean-literal-compare': 'error',
Expand Down

0 comments on commit d1e6352

Please sign in to comment.