@rxap/config 16.0.0-dev.1 → 16.0.0-dev.3
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/CHANGELOG.md +261 -0
- package/README.md +8 -63
- package/esm2022/index.mjs +1 -1
- package/esm2022/lib/config-loader.service.mjs +9 -9
- package/esm2022/lib/config.service.mjs +79 -80
- package/esm2022/lib/tokens.mjs +1 -1
- package/esm2022/lib/types.mjs +1 -1
- package/esm2022/rxap-config.mjs +1 -1
- package/fesm2022/rxap-config.mjs +81 -80
- package/fesm2022/rxap-config.mjs.map +1 -1
- package/lib/config.service.d.ts +5 -5
- package/package.json +35 -38
- package/LICENSE +0 -21
- package/collection.json +0 -15
- package/migration.json +0 -4
- package/src/schematics/ng-add/index.d.ts +0 -3
- package/src/schematics/ng-add/index.js +0 -59
- package/src/schematics/ng-add/index.js.map +0 -1
- package/src/schematics/ng-add/schema.json +0 -15
- package/src/schematics/side-load/index.d.ts +0 -3
- package/src/schematics/side-load/index.js +0 -27
- package/src/schematics/side-load/index.js.map +0 -1
- package/src/schematics/side-load/schema.json +0 -29
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
# Change Log
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
|
+
|
|
6
|
+
# [16.0.0-dev.3](https://gitlab.com/rxap/packages/compare/@rxap/config@16.0.0-dev.2...@rxap/config@16.0.0-dev.3) (2023-07-10)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- restructure and merge mono repos packages, schematics, plugins and nest ([653b4cd](https://gitlab.com/rxap/packages/commit/653b4cd39fc92d322df9b3959651fea0aa6079da))
|
|
11
|
+
|
|
12
|
+
# [16.0.0-dev.2](https://gitlab.com/rxap/packages/compare/@rxap/config@16.0.0-dev.1...@rxap/config@16.0.0-dev.2) (2023-05-31)
|
|
13
|
+
|
|
14
|
+
**Note:** Version bump only for package @rxap/config
|
|
15
|
+
|
|
16
|
+
# [16.0.0-dev.1](https://gitlab.com/rxap/packages/compare/@rxap/config@16.0.0-dev.0...@rxap/config@16.0.0-dev.1) (2023-05-18)
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
- update rxap packagedependencies ([6e12567](https://gitlab.com/rxap/packages/commit/6e12567c05ee3c504da5079cb393660f2ab4cd30))
|
|
21
|
+
|
|
22
|
+
# [16.0.0-dev.0](https://gitlab.com/rxap/packages/compare/@rxap/config@15.0.0...@rxap/config@16.0.0-dev.0) (2023-05-18)
|
|
23
|
+
|
|
24
|
+
### chore
|
|
25
|
+
|
|
26
|
+
- upgrade to nrwl 16.x.x ([12dd87e](https://gitlab.com/rxap/packages/commit/12dd87ef38d465c8af33cd26f7d5d7714bf7c392))
|
|
27
|
+
|
|
28
|
+
### BREAKING CHANGES
|
|
29
|
+
|
|
30
|
+
- upgrade nrwl 16.x.x
|
|
31
|
+
|
|
32
|
+
# [15.0.0](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.4...@rxap/config@15.0.0) (2023-05-17)
|
|
33
|
+
|
|
34
|
+
### chore
|
|
35
|
+
|
|
36
|
+
- upgrade to nrwl 15.x.x ([ad95577](https://gitlab.com/rxap/packages/commit/ad95577538adc5cd134cde8d1ff3b8fad52c9c2b))
|
|
37
|
+
|
|
38
|
+
### BREAKING CHANGES
|
|
39
|
+
|
|
40
|
+
- upgrade nrwl 15.x.x
|
|
41
|
+
|
|
42
|
+
## [14.1.4](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.4-dev.0...@rxap/config@14.1.4) (2023-05-17)
|
|
43
|
+
|
|
44
|
+
**Note:** Version bump only for package @rxap/config
|
|
45
|
+
|
|
46
|
+
## [14.1.4-dev.0](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.3...@rxap/config@14.1.4-dev.0) (2023-04-18)
|
|
47
|
+
|
|
48
|
+
### Bug Fixes
|
|
49
|
+
|
|
50
|
+
- show error in overlay box instead ofalert ([af37e19](https://gitlab.com/rxap/packages/commit/af37e19e8caba07e9cc21485a9582585e544879d))
|
|
51
|
+
- show error in overlay box instead ofalert ([c4c78ab](https://gitlab.com/rxap/packages/commit/c4c78ab49a57e159d86730f90cc5448edaaa1dc7))
|
|
52
|
+
|
|
53
|
+
## [14.1.3](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.2...@rxap/config@14.1.3) (2022-12-14)
|
|
54
|
+
|
|
55
|
+
**Note:** Version bump only for package @rxap/config
|
|
56
|
+
|
|
57
|
+
## [14.1.2](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.1...@rxap/config@14.1.2) (2022-12-13)
|
|
58
|
+
|
|
59
|
+
**Note:** Version bump only for package @rxap/config
|
|
60
|
+
|
|
61
|
+
## [14.1.1](https://gitlab.com/rxap/packages/compare/@rxap/config@14.1.0...@rxap/config@14.1.1) (2022-10-31)
|
|
62
|
+
|
|
63
|
+
### Bug Fixes
|
|
64
|
+
|
|
65
|
+
- check if partial config is notnull ([fef5c5e](https://gitlab.com/rxap/packages/commit/fef5c5e8dc7cc2507b31f2c4424020386b118f21))
|
|
66
|
+
|
|
67
|
+
# [14.1.0](https://gitlab.com/rxap/packages/compare/@rxap/config@14.0.1...@rxap/config@14.1.0) (2022-10-31)
|
|
68
|
+
|
|
69
|
+
### Bug Fixes
|
|
70
|
+
|
|
71
|
+
- change to asyncvalidation ([8363721](https://gitlab.com/rxap/packages/commit/83637213fa134046da9c6fc6dd6a4ee034a6c106))
|
|
72
|
+
- resolve config promise ([e193e38](https://gitlab.com/rxap/packages/commit/e193e38c03598b33d1d1b976b2f76f2acbeaf8cf))
|
|
73
|
+
- use AnySchema instead of ObjectSchama as schematype ([85a2dd5](https://gitlab.com/rxap/packages/commit/85a2dd52f1561948640576f1c42198afd9b4a14c))
|
|
74
|
+
|
|
75
|
+
### Features
|
|
76
|
+
|
|
77
|
+
- support joi configvalidation ([eafea07](https://gitlab.com/rxap/packages/commit/eafea07385967a0b7051632e59e4ef6362af333b))
|
|
78
|
+
|
|
79
|
+
## [14.0.1](https://gitlab.com/rxap/packages/compare/@rxap/config@13.0.0...@rxap/config@14.0.1) (2022-09-17)
|
|
80
|
+
|
|
81
|
+
**Note:** Version bump only for package @rxap/config
|
|
82
|
+
|
|
83
|
+
# [13.0.0](https://gitlab.com/rxap/packages/compare/@rxap/config@13.0.0-next.1...@rxap/config@13.0.0) (2022-09-11)
|
|
84
|
+
|
|
85
|
+
**Note:** Version bump only for package @rxap/config
|
|
86
|
+
|
|
87
|
+
# [13.0.0-next.1](https://gitlab.com/rxap/packages/compare/@rxap/config@13.0.0-next.0...@rxap/config@13.0.0-next.1) (2022-03-29)
|
|
88
|
+
|
|
89
|
+
**Note:** Version bump only for package @rxap/config
|
|
90
|
+
|
|
91
|
+
# [13.0.0-next.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.3.0...@rxap/config@13.0.0-next.0) (2022-02-19)
|
|
92
|
+
|
|
93
|
+
### Build System
|
|
94
|
+
|
|
95
|
+
- upgrade to nrwl/angular13.x.x ([f8920e7](https://gitlab.com/rxap/packages/commit/f8920e7dde7bd2d4b4efac2b7097543d51482f81))
|
|
96
|
+
|
|
97
|
+
### BREAKING CHANGES
|
|
98
|
+
|
|
99
|
+
- update the core nrwl/angular packages to 13.x.x
|
|
100
|
+
|
|
101
|
+
Signed-off-by: Merzough Münker <mmuenker@digitaix.com>
|
|
102
|
+
|
|
103
|
+
# [12.3.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.3.0-next.0...@rxap/config@12.3.0) (2021-08-02)
|
|
104
|
+
|
|
105
|
+
**Note:** Version bump only for package @rxap/config
|
|
106
|
+
|
|
107
|
+
# [12.3.0-next.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.2.0...@rxap/config@12.3.0-next.0) (2021-07-28)
|
|
108
|
+
|
|
109
|
+
### Features
|
|
110
|
+
|
|
111
|
+
- **schematics:** add side-loadschematic ([1579bfd](https://gitlab.com/rxap/packages/commit/1579bfd3cd1238fefaf7562a69d05f9c1129222e))
|
|
112
|
+
|
|
113
|
+
# [12.2.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.2.0-next.2...@rxap/config@12.2.0) (2021-07-22)
|
|
114
|
+
|
|
115
|
+
**Note:** Version bump only for package @rxap/config
|
|
116
|
+
|
|
117
|
+
# [12.2.0-alpha.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.2.0-next.2...@rxap/config@12.2.0-alpha.0) (2021-07-20)
|
|
118
|
+
|
|
119
|
+
**Note:** Version bump only for package @rxap/config
|
|
120
|
+
|
|
121
|
+
# [12.2.0-next.2](https://gitlab.com/rxap/packages/compare/@rxap/config@12.2.0-next.1...@rxap/config@12.2.0-next.2) (2021-07-20)
|
|
122
|
+
|
|
123
|
+
### Bug Fixes
|
|
124
|
+
|
|
125
|
+
- add required option ([3c89387](https://gitlab.com/rxap/packages/commit/3c89387e5369c09054d1859fe062cbd3b56f84bb))
|
|
126
|
+
|
|
127
|
+
# [12.2.0-next.1](https://gitlab.com/rxap/packages/compare/@rxap/config@12.2.0-next.0...@rxap/config@12.2.0-next.1) (2021-07-20)
|
|
128
|
+
|
|
129
|
+
### Bug Fixes
|
|
130
|
+
|
|
131
|
+
- add side load log ([0d51a2b](https://gitlab.com/rxap/packages/commit/0d51a2b5b1095aec3873b24e49bc28588f43af7b))
|
|
132
|
+
|
|
133
|
+
# [12.2.0-next.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.1.0...@rxap/config@12.2.0-next.0) (2021-07-20)
|
|
134
|
+
|
|
135
|
+
### Features
|
|
136
|
+
|
|
137
|
+
- add SideLoad method ([711ab67](https://gitlab.com/rxap/packages/commit/711ab67c2c05c690be9d0e42539bd83a80f96440))
|
|
138
|
+
|
|
139
|
+
# [12.1.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.1.0-next.0...@rxap/config@12.1.0) (2021-07-09)
|
|
140
|
+
|
|
141
|
+
**Note:** Version bump only for package @rxap/config
|
|
142
|
+
|
|
143
|
+
# [12.1.0-next.0](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.7...@rxap/config@12.1.0-next.0) (2021-07-08)
|
|
144
|
+
|
|
145
|
+
### Features
|
|
146
|
+
|
|
147
|
+
- add ng-add logic to update projectfiles ([68641ec](https://gitlab.com/rxap/packages/commit/68641ec726e2f12c4e9481f0943801b5d901845e))
|
|
148
|
+
|
|
149
|
+
## [12.0.7](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.6...@rxap/config@12.0.7) (2021-06-24)
|
|
150
|
+
|
|
151
|
+
**Note:** Version bump only for package @rxap/config
|
|
152
|
+
|
|
153
|
+
## [12.0.6](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.5...@rxap/config@12.0.6) (2021-06-23)
|
|
154
|
+
|
|
155
|
+
**Note:** Version bump only for package @rxap/config
|
|
156
|
+
|
|
157
|
+
## [12.0.5](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.4...@rxap/config@12.0.5) (2021-06-23)
|
|
158
|
+
|
|
159
|
+
**Note:** Version bump only for package @rxap/config
|
|
160
|
+
|
|
161
|
+
## [12.0.4](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.3...@rxap/config@12.0.4) (2021-06-14)
|
|
162
|
+
|
|
163
|
+
**Note:** Version bump only for package @rxap/config
|
|
164
|
+
|
|
165
|
+
## [12.0.3](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.2...@rxap/config@12.0.3) (2021-06-10)
|
|
166
|
+
|
|
167
|
+
### Bug Fixes
|
|
168
|
+
|
|
169
|
+
- explicit imports ([373bf4c](https://gitlab.com/rxap/packages/commit/373bf4c739deb42441db92dd6b043b9af723d25f))
|
|
170
|
+
|
|
171
|
+
## [12.0.2](https://gitlab.com/rxap/packages/compare/@rxap/config@11.1.2...@rxap/config@12.0.2) (2021-06-09)
|
|
172
|
+
|
|
173
|
+
### Bug Fixes
|
|
174
|
+
|
|
175
|
+
- add readme generator ([aca8e49](https://gitlab.com/rxap/packages/commit/aca8e495f06d81edf14e56fdd1e6a3c2d7de4c50))
|
|
176
|
+
|
|
177
|
+
## [12.0.1](https://gitlab.com/rxap/packages/compare/@rxap/config@12.0.0...@rxap/config@12.0.1) (2021-05-24)
|
|
178
|
+
|
|
179
|
+
### Bug Fixes
|
|
180
|
+
|
|
181
|
+
- add readme generator ([aca8e49](https://gitlab.com/rxap/packages/commit/aca8e495f06d81edf14e56fdd1e6a3c2d7de4c50))
|
|
182
|
+
|
|
183
|
+
# [12.0.0](https://gitlab.com/rxap/packages/compare/@rxap/config@11.1.1...@rxap/config@12.0.0) (2021-05-24)
|
|
184
|
+
|
|
185
|
+
**Note:** Version bump only for package @rxap/config
|
|
186
|
+
|
|
187
|
+
## [11.1.1](https://gitlab.com/rxap/packages/compare/@rxap/config@11.1.0...@rxap/config@11.1.1) (2021-04-30)
|
|
188
|
+
|
|
189
|
+
### Bug Fixes
|
|
190
|
+
|
|
191
|
+
- **schematics:** update module toesnext ([d1e2cd2](https://gitlab.com/rxap/packages/commit/d1e2cd252f3866471935131187b3acaefe2cca82))
|
|
192
|
+
- **schematics:** update to general schematicstsconfig ([83e5f9a](https://gitlab.com/rxap/packages/commit/83e5f9a0cf1810686a503425d87a5e4ae30b8c84))
|
|
193
|
+
|
|
194
|
+
# [11.1.0](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.10...@rxap/config@11.1.0) (2021-04-22)
|
|
195
|
+
|
|
196
|
+
### Features
|
|
197
|
+
|
|
198
|
+
- **config-service:** add methodgetOrThrow ([e7ca009](https://gitlab.com/rxap/packages/commit/e7ca00931d9d5017f54d3d5482864b180fccafd4))
|
|
199
|
+
|
|
200
|
+
## [11.0.10](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.9...@rxap/config@11.0.10) (2021-04-21)
|
|
201
|
+
|
|
202
|
+
### Bug Fixes
|
|
203
|
+
|
|
204
|
+
- update default config filepath ([ca53d05](https://gitlab.com/rxap/packages/commit/ca53d05eb9605d35bda1fac41ee3c3c09683f0b0))
|
|
205
|
+
|
|
206
|
+
## [11.0.9](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.8...@rxap/config@11.0.9) (2021-03-19)
|
|
207
|
+
|
|
208
|
+
### Bug Fixes
|
|
209
|
+
|
|
210
|
+
- update peer dependencies ([954fde4](https://gitlab.com/rxap/packages/commit/954fde47836ff0c1f25a77c33ff871ddc7685b6c))
|
|
211
|
+
|
|
212
|
+
## [11.0.8](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.7...@rxap/config@11.0.8) (2021-03-19)
|
|
213
|
+
|
|
214
|
+
### Bug Fixes
|
|
215
|
+
|
|
216
|
+
- update peer dependencies ([dd22b0c](https://gitlab.com/rxap/packages/commit/dd22b0ce053bc266c7aea659a2faf3be39f424e7))
|
|
217
|
+
|
|
218
|
+
## [11.0.7](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.6...@rxap/config@11.0.7) (2021-03-19)
|
|
219
|
+
|
|
220
|
+
### Bug Fixes
|
|
221
|
+
|
|
222
|
+
- update peer dependencies ([2eeb7eb](https://gitlab.com/rxap/packages/commit/2eeb7eb85eedd6d610e855dc1724c7153cf01fd0))
|
|
223
|
+
- update peer dependencies ([c7d1267](https://gitlab.com/rxap/packages/commit/c7d12671f3efc198985cddee92caa2558e74b023))
|
|
224
|
+
|
|
225
|
+
## [11.0.6](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.5...@rxap/config@11.0.6) (2021-03-10)
|
|
226
|
+
|
|
227
|
+
### Bug Fixes
|
|
228
|
+
|
|
229
|
+
- default value return ([b2f7fb3](https://gitlab.com/rxap/packages/commit/b2f7fb33fa1187feb06332cd5d42341f322f71bc))
|
|
230
|
+
|
|
231
|
+
## [11.0.5](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.4...@rxap/config@11.0.5) (2021-03-09)
|
|
232
|
+
|
|
233
|
+
### Bug Fixes
|
|
234
|
+
|
|
235
|
+
- soft fail if the config path is notdefined ([6eeed25](https://gitlab.com/rxap/packages/commit/6eeed2545e0603c6e8b852351fec52fe03d916c0))
|
|
236
|
+
|
|
237
|
+
## [11.0.4](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.3...@rxap/config@11.0.4) (2021-02-04)
|
|
238
|
+
|
|
239
|
+
**Note:** Version bump only for package @rxap/config
|
|
240
|
+
|
|
241
|
+
## [11.0.3](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.2...@rxap/config@11.0.3) (2021-01-15)
|
|
242
|
+
|
|
243
|
+
**Note:** Version bump only for package @rxap/config
|
|
244
|
+
|
|
245
|
+
## [11.0.2](https://gitlab.com/rxap/packages/compare/@rxap/config@10.1.0...@rxap/config@11.0.2) (2021-01-15)
|
|
246
|
+
|
|
247
|
+
**Note:** Version bump only for package @rxap/config
|
|
248
|
+
|
|
249
|
+
## [11.0.1](https://gitlab.com/rxap/packages/compare/@rxap/config@11.0.0...@rxap/config@11.0.1) (2021-01-05)
|
|
250
|
+
|
|
251
|
+
**Note:** Version bump only for package @rxap/config
|
|
252
|
+
|
|
253
|
+
# [11.0.0](https://gitlab.com/rxap/packages/compare/@rxap/config@10.0.0...@rxap/config@11.0.0) (2021-01-03)
|
|
254
|
+
|
|
255
|
+
**Note:** Version bump only for package @rxap/config
|
|
256
|
+
|
|
257
|
+
# 10.0.0 (2021-01-03)
|
|
258
|
+
|
|
259
|
+
### Bug Fixes
|
|
260
|
+
|
|
261
|
+
- custom property keygeneration ([b6e6d23](https://gitlab.com/rxap/packages/commit/b6e6d23215f0b35e0de2d35003b186a3d435b8e4))
|
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
@rxap/config
|
|
2
|
-
|
|
1
|
+
# @rxap/config
|
|
2
|
+
> Simple config file manager for angular applications.
|
|
3
3
|
|
|
4
4
|
[](https://www.npmjs.com/package/@rxap/config)
|
|
5
5
|
[](https://commitizen.github.io/cz-cli/)
|
|
@@ -8,70 +8,15 @@
|
|
|
8
8
|

|
|
9
9
|

|
|
10
10
|
|
|
11
|
-
> Simple config file manager for angular applications.
|
|
12
|
-
|
|
13
11
|
- [Installation](#installation)
|
|
14
|
-
- [Get started](#get-started)
|
|
15
|
-
- [Schematics](#schematics)
|
|
16
12
|
|
|
17
13
|
# Installation
|
|
18
14
|
|
|
15
|
+
**Add the package to your workspace:**
|
|
16
|
+
```bash
|
|
17
|
+
yarn add @rxap/config
|
|
19
18
|
```
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
*Setup the package @rxap/config for the workspace.*
|
|
24
|
-
|
|
25
|
-
# Get started
|
|
26
|
-
|
|
27
|
-
Update the angular application `main.ts` to support @rxap/config.
|
|
28
|
-
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
// (optional) Defines a list of configuration urls.
|
|
32
|
-
ConfigService.Urls = ['/config/config.json'];
|
|
33
|
-
|
|
34
|
-
// Ensures that the configuration is loaded before the angular application is started
|
|
35
|
-
Promise.all([ConfigService.Load()]).then(() =>
|
|
36
|
-
platformBrowserDynamic()
|
|
37
|
-
.bootstrapModule(AppModule)
|
|
38
|
-
.catch((err) => console.error(err))
|
|
39
|
-
);
|
|
40
|
-
|
|
19
|
+
**Install peer dependencies:**
|
|
20
|
+
```bash
|
|
21
|
+
yarn add
|
|
41
22
|
```
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
# Schematics
|
|
45
|
-
|
|
46
|
-
## ng-add
|
|
47
|
-
> Setup the package @rxap/config for the workspace.
|
|
48
|
-
|
|
49
|
-
```
|
|
50
|
-
ng g @rxap/config:ng-add
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
Option | Type | Default | Description
|
|
54
|
-
--- | --- | --- | ---
|
|
55
|
-
project | string | | The project where the environment feature should be added
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
## side-load
|
|
59
|
-
> Add a side load config to the project main file.
|
|
60
|
-
|
|
61
|
-
```
|
|
62
|
-
ng g @rxap/config:side-load
|
|
63
|
-
```
|
|
64
|
-
|
|
65
|
-
Option | Type | Default | Description
|
|
66
|
-
--- | --- | --- | ---
|
|
67
|
-
project | string | | The project name
|
|
68
|
-
url | string | | Url for the config that should be side loaded
|
|
69
|
-
propertyPath | string | | Property path where the config should be added
|
|
70
|
-
required | boolean | false |
|
|
71
|
-
|
|
72
|
-
| Required |
|
|
73
|
-
| --- |
|
|
74
|
-
| project |
|
|
75
|
-
| url |
|
|
76
|
-
| propertyPath |
|
|
77
|
-
|
package/esm2022/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export * from './lib/config.service';
|
|
2
2
|
export * from './lib/tokens';
|
|
3
3
|
export * from './lib/config-loader.service';
|
|
4
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
4
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy9hbmd1bGFyL2NvbmZpZy9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsY0FBYyxzQkFBc0IsQ0FBQztBQUNyQyxjQUFjLGNBQWMsQ0FBQztBQUM3QixjQUFjLDZCQUE2QixDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9saWIvY29uZmlnLnNlcnZpY2UnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvdG9rZW5zJztcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvbmZpZy1sb2FkZXIuc2VydmljZSc7XG4iXX0=
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { Injectable,
|
|
1
|
+
import { Inject, Injectable, } from '@angular/core';
|
|
2
|
+
import { firstValueFrom, } from 'rxjs';
|
|
2
3
|
import { HttpClient } from '@angular/common/http';
|
|
3
|
-
import { finalize, share } from 'rxjs/operators';
|
|
4
|
+
import { finalize, share, } from 'rxjs/operators';
|
|
4
5
|
import * as i0 from "@angular/core";
|
|
5
6
|
import * as i1 from "@angular/common/http";
|
|
6
|
-
class ConfigLoaderService {
|
|
7
|
+
export class ConfigLoaderService {
|
|
7
8
|
constructor(http) {
|
|
8
9
|
this.http = http;
|
|
9
10
|
this.configs = new Map();
|
|
@@ -18,17 +19,16 @@ class ConfigLoaderService {
|
|
|
18
19
|
}
|
|
19
20
|
const loading$ = this.http.get(url).pipe(finalize(() => this.configLoading.delete(url)), share());
|
|
20
21
|
this.configLoading.set(url, loading$);
|
|
21
|
-
return loading
|
|
22
|
+
return firstValueFrom(loading$);
|
|
22
23
|
}
|
|
23
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.
|
|
24
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.
|
|
24
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: ConfigLoaderService, deps: [{ token: HttpClient }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
25
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: ConfigLoaderService, providedIn: 'root' }); }
|
|
25
26
|
}
|
|
26
|
-
|
|
27
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.2", ngImport: i0, type: ConfigLoaderService, decorators: [{
|
|
27
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.4", ngImport: i0, type: ConfigLoaderService, decorators: [{
|
|
28
28
|
type: Injectable,
|
|
29
29
|
args: [{ providedIn: 'root' }]
|
|
30
30
|
}], ctorParameters: function () { return [{ type: i1.HttpClient, decorators: [{
|
|
31
31
|
type: Inject,
|
|
32
32
|
args: [HttpClient]
|
|
33
33
|
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