mantra-cli
mantra-cli copied to clipboard
skip creation of routes
I usually only use routes in core, because having routes in multiple modules may lead to re-renderings (see https://github.com/mantrajs/mantra-core/issues/9), so it would be cool to just be able to disable route generation in other modules than core (maybe via setting)
That's fair. Do you have plans for how to implement it?
hmm...
- [ ] config
createRoutesOnModules: true/false
- [ ] do not create route file when createRoutesOnModules is false (if its not core module, i think we should always create it)
- [ ] verfiy that the module index file does not import the route file when createRoutesOnModules is false
that makes sense. Feel free to open a PR and I will review it before we release.
This would also help with React-router as routes for rr are only in core.