Skip to content

Commit 438fad7

Browse files
Ensure AuthConfigService is exported before AuthClientConfig (#413)
1 parent 96c11bb commit 438fad7

File tree

1 file changed

+16
-15
lines changed

1 file changed

+16
-15
lines changed

projects/auth0-angular/src/lib/auth.config.ts

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,22 @@ export interface AppState {
194194
* ```
195195
*
196196
*/
197+
198+
/**
199+
* Injection token for accessing configuration.
200+
*
201+
* @usageNotes
202+
*
203+
* Use the `Inject` decorator to access the configuration from a service or component:
204+
*
205+
* ```
206+
* class MyService(@Inject(AuthConfigService) config: AuthConfig) {}
207+
* ```
208+
*/
209+
export const AuthConfigService = new InjectionToken<AuthConfig>(
210+
'auth0-angular.config'
211+
);
212+
197213
@Injectable({ providedIn: 'root' })
198214
export class AuthClientConfig {
199215
private config?: AuthConfig;
@@ -220,18 +236,3 @@ export class AuthClientConfig {
220236
return this.config as AuthConfig;
221237
}
222238
}
223-
224-
/**
225-
* Injection token for accessing configuration.
226-
*
227-
* @usageNotes
228-
*
229-
* Use the `Inject` decorator to access the configuration from a service or component:
230-
*
231-
* ```
232-
* class MyService(@Inject(AuthConfigService) config: AuthConfig) {}
233-
* ```
234-
*/
235-
export const AuthConfigService = new InjectionToken<AuthConfig>(
236-
'auth0-angular.config'
237-
);

0 commit comments

Comments
 (0)