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

Documentation for 'import/no-extraneous-dependencies' is missing #2727

Open
cseas opened this issue Feb 14, 2023 · 13 comments · May be fixed by #2748
Open

Documentation for 'import/no-extraneous-dependencies' is missing #2727

cseas opened this issue Feb 14, 2023 · 13 comments · May be fixed by #2748

Comments

@cseas
Copy link

cseas commented Feb 14, 2023

The rule is set to error in the config:
https://github.com/airbnb/javascript/blob/master/packages/eslint-config-airbnb-base/rules/imports.js#L71

But there's no mention of it in the guide:
https://github.com/airbnb/javascript/blob/master/README.md

This rule should be mentioned under the Modules section.

@ljharb
Copy link
Collaborator

ljharb commented Feb 14, 2023

Sure, that's fine. It's been a best practice in node for over a decade so I guess it just went without saying :-)

@MohitBansal321
Copy link

Sure, that's fine. It's been a best practice in node for over a decade so I guess it just went without saying :-)

I didn't find link related to this rule on eslint

@ljharb
Copy link
Collaborator

ljharb commented Feb 22, 2023

It's part of eslint-plugin-import.

@MohitBansal321
Copy link

It's part of eslint-plugin-import.

Link (this one?)
on which part of the modules should be added?

@ljharb
Copy link
Collaborator

ljharb commented Feb 23, 2023

Yep, that's the rule.

I guess as a new section at the end of Modules?

@meddy672 meddy672 linked a pull request Mar 23, 2023 that will close this issue
@meddy672
Copy link

I have a PR up. Please take a look.

@Vivek-04022001

This comment was marked as outdated.

@ljharb

This comment was marked as resolved.

@utkarsh-shrivastav77

This comment was marked as outdated.

@ljharb

This comment was marked as resolved.

@cyberwarrior-20
Copy link

hi @cseas i can solve this issue please assign me

@angeloreale
Copy link

angeloreale commented Apr 18, 2024

My .50 cents? Why is it something should be made a code style pattern if it can directly affect bundle sizes for ES modules?

@ljharb
Copy link
Collaborator

ljharb commented Apr 18, 2024

Everything can affect that, and that’s just not a rubric anyone should be applying to how your code is written.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants