Core Module in Ionic

#1

As most of you know, Angular suggests core.module for singleton services. For example auth.service is a service that should be in core module. And we put core module in -only- app.module.

In ionic samples i can’t see any core module implementation. Is it because of all ionic pages are lazy and lazy pages creates their own instance of services? Or is there any other reason that developers do not prefer to use core module in ionic?

Thanks in advance.

#2

They’re samples so their focus is probably on demonstrating a particular feature (rather than application structure).

You should be able to find some blog posts that discuss Angular / Ionic best (good) practices:

1 Like