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

feat(experimental-utils): use mergable interface for settings property #3556

Merged
merged 1 commit into from Jun 20, 2021
Merged

feat(experimental-utils): use mergable interface for settings property #3556

merged 1 commit into from Jun 20, 2021

Conversation

G-Rath
Copy link
Contributor

@G-Rath G-Rath commented Jun 19, 2021

This lets us do declaration merging to define settings at the plugin level e.g.

interface ESLintPluginJestSettings {
  describeBlocks: readonly string[];
  hookNames: readonly string[];
}

declare module '@typescript-eslint/experimental-utils/dist/ts-eslint/Rule' {
  export interface SharedConfigurationSettings
    extends ESLintPluginJestSettings {}
}

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @G-Rath!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint. As a thank you, your profile/company logo will be added to our main README which receives thousands of unique visitors per day.

@nx-cloud
Copy link

nx-cloud bot commented Jun 19, 2021

Nx Cloud Report

CI ran the following commands for commit 3bc6a8c. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch

Status Command
#000000 nx run-many --target=build --all --parallel
#000000 nx run-many --target=typecheck --all --parallel

Sent with 💌 from NxCloud.

@nx-cloud
Copy link

nx-cloud bot commented Jun 19, 2021

Nx Cloud Report

CI ran the following commands for commit fdf79a1. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch

Status Command
#000000 nx run-many --target=build --all --parallel
#000000 nx run-many --target=typecheck --all --parallel

Sent with 💌 from NxCloud.

@bradzacher bradzacher added the enhancement New feature or request label Jun 20, 2021
@bradzacher bradzacher added the awaiting response Issues waiting for a reply from the OP or another party label Jun 20, 2021
@G-Rath G-Rath requested a review from bradzacher June 20, 2021 21:27
MichaelDeBoey
MichaelDeBoey previously approved these changes Jun 20, 2021
* Plugins can add their settings using declaration
* merging against this interface.
*/
// eslint-disable-next-line @typescript-eslint/no-empty-interface
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't this unnecessary now?
i'm surprised our lint rule didn't fire on this

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay weird... none of the checks ran on your last commit

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quite right, and yeah, that is weird...

I'll rebase to resolve the conflict and remove this at the same time, which'll hopefully trigger CI.

bradzacher
bradzacher previously approved these changes Jun 20, 2021
Copy link
Member

@bradzacher bradzacher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you conflicted with your previous PR!
otherwise LGTM

@G-Rath G-Rath dismissed stale reviews from bradzacher and MichaelDeBoey via 3bc6a8c June 20, 2021 22:58
@codecov
Copy link

codecov bot commented Jun 20, 2021

Codecov Report

Merging #3556 (3bc6a8c) into master (ffbb3cf) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #3556   +/-   ##
=======================================
  Coverage   92.63%   92.63%           
=======================================
  Files         325      325           
  Lines       11236    11236           
  Branches     3168     3168           
=======================================
  Hits        10409    10409           
  Misses        367      367           
  Partials      460      460           
Flag Coverage Δ
unittest 92.63% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ackages/experimental-utils/src/ts-eslint/Linter.ts 100.00% <ø> (ø)
...ges/experimental-utils/src/ts-eslint/RuleTester.ts 100.00% <ø> (ø)
...tal-utils/src/ast-utils/eslint-utils/predicates.ts 100.00% <0.00%> (ø)

@G-Rath G-Rath requested a review from bradzacher June 20, 2021 22:59
@bradzacher bradzacher merged commit abfc19b into typescript-eslint:master Jun 20, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 21, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
awaiting response Issues waiting for a reply from the OP or another party enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants