@dereekb/dbx-core 11.0.18 → 11.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/environment/index.mjs +3 -0
- package/esm2022/lib/environment/service/environment.mjs +6 -0
- package/esm2022/lib/environment/service/environment.service.mjs +33 -0
- package/esm2022/lib/index.mjs +2 -1
- package/fesm2022/dereekb-dbx-core.mjs +37 -1
- package/fesm2022/dereekb-dbx-core.mjs.map +1 -1
- package/lib/environment/index.d.ts +2 -0
- package/lib/environment/service/environment.d.ts +21 -0
- package/lib/environment/service/environment.service.d.ts +17 -0
- package/lib/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* App environment details
|
|
3
|
+
*/
|
|
4
|
+
export declare abstract class DbxAppEnviroment {
|
|
5
|
+
/**
|
|
6
|
+
* Whether or not this is a production environment.
|
|
7
|
+
*/
|
|
8
|
+
abstract production: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Whether or not this is a testing environment.
|
|
11
|
+
*
|
|
12
|
+
* Generally "production" is false when this is true.
|
|
13
|
+
*/
|
|
14
|
+
abstract testing?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Whether or not this is a staging environment.
|
|
17
|
+
*
|
|
18
|
+
* Generally "production" is true when this is true.
|
|
19
|
+
*/
|
|
20
|
+
abstract staging?: boolean;
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { DbxAppEnviroment } from './environment';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Service for accessing the app's environment details.
|
|
5
|
+
*/
|
|
6
|
+
export declare class DbxAppEnviromentService {
|
|
7
|
+
readonly environment: DbxAppEnviroment;
|
|
8
|
+
get isProduction(): boolean;
|
|
9
|
+
get isStaging(): boolean;
|
|
10
|
+
get isTesting(): boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Returns the environment, typed as a specific type.
|
|
13
|
+
*/
|
|
14
|
+
getEnvironment<T extends DbxAppEnviroment>(): T;
|
|
15
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DbxAppEnviromentService, never>;
|
|
16
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DbxAppEnviromentService>;
|
|
17
|
+
}
|
package/lib/index.d.ts
CHANGED