The ionic generators are intended for small apps with just a few pages. If you’re using a larger app, the file structure in the official Angular Style Guide is better. You need to modify that style guide a bit, because lazy loading is different in Ionic. I put providers in a separate sub-feature module so they can be registered in app.module.ts,without affecting the parts of the feature module that I want to lazy load later.
↧