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

import/no-extraneous-dependencies should check export from #1049

Closed
penx opened this issue Mar 22, 2018 · 2 comments · Fixed by #1550
Closed

import/no-extraneous-dependencies should check export from #1049

penx opened this issue Mar 22, 2018 · 2 comments · Fixed by #1550

Comments

@penx
Copy link

penx commented Mar 22, 2018

The following is correctly picked up by import/no-extraneous-dependencies

import { myUtil } from '@my/utils';
export { myUtil };

The following code is equivalent but does not get picked up by import/no-extraneous-dependencies

export { myUtil } from '@my/utils';

Can support for this be added?

penx added a commit to govuk-react/govuk-react that referenced this issue Mar 22, 2018
Ideally this should be automatically picked up but awaiting feedback on associated eslint plugin - import-js/eslint-plugin-import#1049
penx added a commit to govuk-react/govuk-react that referenced this issue Mar 26, 2018
Ideally this should be automatically picked up but awaiting feedback on associated eslint plugin - import-js/eslint-plugin-import#1049
penx added a commit to govuk-react/govuk-react that referenced this issue Apr 6, 2018
eslint needs to be configured to pick up exports that aren't in package.json

see import-js/eslint-plugin-import#1049

In the meantime we are including @govuk-react/storybook as a dependency, which will help ensure subdependencies are included.
penx added a commit to govuk-react/govuk-react that referenced this issue Apr 6, 2018
`@govuk-react/loading-box` wasn't a sub dependency of govuk-react. We want issues like this to be picked up automatically.

eslint needs to be configured to pick up exports that aren't in package.json, but this can't be done right now, see import-js/eslint-plugin-import#1049.

In the meantime we are including @govuk-react/storybook as a dependency, which will help ensure the storybook sub dependencies are included.

Also:

- remove package lock, using yarn as standard
- update yarn lock
- remove loading box package lock
- fix to eslint command to include subfolders of src
- add  devDependencies to hoc package
- add  dependencies to storybook package
- govuk-react/storybook as dependency of govuk-react (temporary)
@marcusdarmstrong
Copy link

Open to contributions on this?

@penx
Copy link
Author

penx commented Dec 2, 2019

I think the ‘help wanted‘ tag from @ljharb means yes 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
3 participants