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

[filename-match-exported] Add setting to allow ignoring an entire directory of files #44

Open
acusti opened this issue Feb 3, 2025 · 0 comments

Comments

@acusti
Copy link

acusti commented Feb 3, 2025

i like the canonical/filename-match-exported rule, but i also use remix (react router) with file-convention based routing, and so the filenames for the files in the routes folder are all based on the URL paths they are associated with (e.g. app/routes/concerts.$city.tsx, app/routes/($lang).categories.tsx) and do not translate to default export variable names.

i suppose there could be some sort of route-file transform or something that cleverly parses the route filenames and deterministically generates the corresponding default export variable name (maybe ConcertsCity for the first example, Categories for the second), but that seems quite tricky and very usecase specific. so i was thinking a simple solution that would allow me to still enable this rule would be to allow ignoring entire directories, so then i could use ignoredDirectories: ['app/routes'] as the config for the rule and still get value from it.

thanks for your consideration and for this great plugin!

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

No branches or pull requests

1 participant