You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
When providing an index file to expose a public API for the contents of a directory, users are still able to import items from the index file and from any of the files within the directory. This allows users to export and use private items that are only intended to be used within the parent directory elsewhere.
Describe the solution you'd like
Restrict the export of items from a directory if an index (barrel) file is present
Is your feature request related to a problem? Please describe.
When providing an index file to expose a public API for the contents of a directory, users are still able to import items from the index file and from any of the files within the directory. This allows users to export and use private items that are only intended to be used within the parent directory elsewhere.
Describe the solution you'd like
Restrict the export of items from a directory if an index (barrel) file is present
Describe alternatives you've considered
-
Additional context
Similar to this, however we would want the restriction to be applied depending on the existence of the
index.ts
filehttps://github.com/import-js/eslint-plugin-import/blob/main/docs/rules/no-internal-modules.md
The text was updated successfully, but these errors were encountered: