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

docs(eslint-plugin): [ban-types] add reference on how to type an empty object #2758

Merged

Conversation

martinfrancois
Copy link
Contributor

@martinfrancois martinfrancois commented Nov 12, 2020

I recently got a ban-types error when specifying an empty object to be allowed ({}), which correctly warned me that this is not what I intended. But the message only offered alternatives for cases that didn't apply to my case in particular. After a lot of digging I found this issue (#2063) thankfully explaining the solution to my problem.

I want to save some other devs the trouble of having to look for a solution in this case (or even worse, some people probably ignoring the error, should they not find a solution). This was also suggested here #2063 (comment)

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @martinfrancois!

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.

packages/eslint-plugin/docs/rules/ban-types.md Outdated Show resolved Hide resolved
packages/eslint-plugin/src/rules/ban-types.ts Outdated Show resolved Hide resolved
@bradzacher bradzacher added awaiting response Issues waiting for a reply from the OP or another party documentation Documentation ("docs") that needs adding/updating labels Nov 13, 2020
@bradzacher bradzacher changed the title feat(eslint-plugin): add reference on how to type an empty object in ban-types docs(eslint-plugin): add reference on how to type an empty object in ban-types Nov 13, 2020
@martinfrancois
Copy link
Contributor Author

@bradzacher thanks for the suggestions! I applied them.

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.

thanks!

@bradzacher bradzacher changed the title docs(eslint-plugin): add reference on how to type an empty object in ban-types docs(eslint-plugin): [ban-types] add reference on how to type an empty object Nov 17, 2020
@bradzacher bradzacher removed the awaiting response Issues waiting for a reply from the OP or another party label Nov 17, 2020
@bradzacher bradzacher merged commit 7af66a7 into typescript-eslint:master Nov 17, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Documentation ("docs") that needs adding/updating
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants