@chjoly wrote:
Nowadays, what is the best/recommended way to set a global constant to be used across the entire app, like an API url string?
I’ve read about creating a service to store the constant and injecting it in your component, whenever it’s needed.
But there is also this: http://ionicframework.com/docs/api/config/Config/
… and this option too: https://stackoverflow.com/questions/41808521/ionic2-what-is-the-best-method-to-store-static-constants-like-api-urls
And a few other options…
Posts: 1
Participants: 1