Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESLint: Simplify exclude for "no-restricted-syntax" rule #1867

Merged
merged 1 commit into from May 18, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
19 changes: 9 additions & 10 deletions .eslintrc.yml
Expand Up @@ -262,7 +262,13 @@ rules:
no-nested-ternary: off
no-new-object: error
no-plusplus: off
no-restricted-syntax: off
no-restricted-syntax:
- error
- selector: 'FunctionDeclaration[async=true]'
message: >
async functions are not allowed outside of the test suite because
older versions of NodeJS do not support them without additional
runtime dependencies. Instead, use explicit Promises.
no-tabs: error
no-ternary: off
no-underscore-dangle: off
Expand Down Expand Up @@ -370,13 +376,6 @@ rules:
yield-star-spacing: off

overrides:
- files: "*"
excludedFiles: "**/__tests__/**"
- files: "**/__tests__/**"
rules:
no-restricted-syntax:
- error
- selector: 'FunctionDeclaration[async=true]'
message: >
async functions are not allowed outside of the test suite because
older versions of NodeJS do not support them without additional
runtime dependencies. Instead, use explicit Promises.
no-restricted-syntax: off