"not-reachable" rule
See original GitHub issueQuestion (or feature request if it isn’t possible at the moment)
Is it possible to declare an “not-reachable” rule, which is an extension of the “no-orphans” rule, but also checks for modules with outgoing imports. This rule would require to specify a list of “entry points”.
Example
Given
src/index.js -> src/mod_a.js
src/mod_a.js -> src/mod_b.js
src/mod_orphan.js -> src/mod_b.js
Then this rule should report src/mod_orphan.js
as “not reachable” (given ["src/index.js"]
as “entry point list”).
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Useless variables in context-free grammars
All variables not marked "reachable" are non-reachable (by a simple induction on the length of derivations). Observe that a CFG has no useless...
Read more >no-unreachable - ESLint - Pluggable JavaScript Linter
This rule disallows unreachable code after return , throw , continue , and break statements. This rule also flags definitions of instance fields...
Read more >The rule I created does not work - Microsoft Support
Cause: Rules run automatically on messages only as you receive or send them. Solution: Manually apply a rule to messages that you have...
Read more >How to Fix It When Outlook Rules Are Not Working - Lifewire
Start by deleting the rule that's not working, then run the Inbox Repair Tool. Fix corruption using an Exchange account.
Read more >Not available rule - Pega Community
Not available rule ... Validation skips, and these rules are invisible to the rule resolution algorithm for all users, including yourself. These rules...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
=> I’ve added a comment to the PR.
hello again @ulrichb. At this moment this is indeed not possible, but it’d be a useful extension of the orphan rule as a ‘dead wood detector’.
I’ll have to mull over what an intuitive interface and a reasonable implementation would be - but it’s likely to be doable.
Kicking around some ideas for a configured rule like that:
and/ or as an
allowed
rule, which might be slightly more readable