How to config different development environment in Angular 2 app
<p>I have a constant file </p>

<pre><code>export class constants {
    public static get API_ENDPOINT(): string { return 'https://dvelopment-server/'; }
}
</code></pre>

<p>And I imported it to my service </p>

<pre><code>private _registrationUrl = constants.API_ENDPOINT+'api/v1/register';
</code></pre>

<p>How can I change the endpont with server change . I have development server staging server and local server. I want app to detect the environment change. </p>

<p>In my angular 1 app I used envserviceprovider for this. Can I use the same in angular 2 app ?</p>