@rxap/config 19.2.0-dev.3 → 19.3.0-dev.0

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.
Files changed (104) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/compodoc/changelog.html +7 -0
  3. package/compodoc/dependencies.html +2 -2
  4. package/compodoc/injectables/ConfigService.html +130 -87
  5. package/compodoc/interfaces/ConfigLoadOptions.html +149 -52
  6. package/compodoc/js/search/search_index.js +2 -2
  7. package/compodoc/miscellaneous/enumerations.html +53 -0
  8. package/compodoc/properties.html +1 -1
  9. package/docs/documentation.json +820 -656
  10. package/docs/html/assets/hierarchy.js +1 -1
  11. package/docs/html/assets/navigation.js +1 -1
  12. package/docs/html/assets/search.js +1 -1
  13. package/docs/html/classes/ConfigLoaderService.html +2 -2
  14. package/docs/html/classes/ConfigService.html +6 -6
  15. package/docs/html/classes/ConfigTestingService.html +2 -2
  16. package/docs/html/enums/ConfigLoadMethod.html +5 -0
  17. package/docs/html/enums/ConfigLoadingStrategy.html +2 -2
  18. package/docs/html/functions/ProvideConfig.html +1 -1
  19. package/docs/html/functions/dnsLookup.html +1 -1
  20. package/docs/html/functions/dnsResolver.html +1 -1
  21. package/docs/html/functions/fetchCidContent.html +1 -1
  22. package/docs/html/functions/fetchCidContentAsJson.html +1 -1
  23. package/docs/html/functions/fetchCidContentViaHttp.html +1 -1
  24. package/docs/html/functions/fetchContentViaHttp.html +1 -1
  25. package/docs/html/functions/raceSuccess.html +2 -2
  26. package/docs/html/hierarchy.html +1 -1
  27. package/docs/html/index.html +2 -2
  28. package/docs/html/interfaces/AppsNavigationConfig.html +2 -2
  29. package/docs/html/interfaces/Config.html +2 -2
  30. package/docs/html/interfaces/ConfigLoadOptions.html +10 -5
  31. package/docs/html/interfaces/LogoConfig.html +2 -2
  32. package/docs/html/interfaces/NavigationConfig.html +2 -2
  33. package/docs/html/interfaces/Oauth2Config.html +2 -2
  34. package/docs/html/interfaces/i18nConfig.html +2 -2
  35. package/docs/html/modules.html +1 -1
  36. package/docs/html/types/AnySchema.html +1 -1
  37. package/docs/html/types/Join.html +1 -1
  38. package/docs/html/types/LanguagesConfig.html +1 -1
  39. package/docs/html/types/Leaves.html +1 -1
  40. package/docs/html/types/NoInferType.html +1 -1
  41. package/docs/html/types/Paths.html +1 -1
  42. package/docs/html/variables/RXAP_CONFIG.html +1 -1
  43. package/docs/markdown/README.md +1 -1
  44. package/docs/markdown/classes/ConfigLoaderService.md +7 -7
  45. package/docs/markdown/classes/ConfigService.md +22 -22
  46. package/docs/markdown/classes/ConfigTestingService.md +8 -8
  47. package/docs/markdown/enumerations/ConfigLoadMethod.md +41 -0
  48. package/docs/markdown/enumerations/ConfigLoadingStrategy.md +4 -4
  49. package/docs/markdown/functions/ProvideConfig.md +2 -2
  50. package/docs/markdown/functions/dnsLookup.md +2 -2
  51. package/docs/markdown/functions/dnsResolver.md +2 -2
  52. package/docs/markdown/functions/fetchCidContent.md +2 -2
  53. package/docs/markdown/functions/fetchCidContentAsJson.md +2 -2
  54. package/docs/markdown/functions/fetchCidContentViaHttp.md +2 -2
  55. package/docs/markdown/functions/fetchContentViaHttp.md +2 -2
  56. package/docs/markdown/functions/raceSuccess.md +2 -2
  57. package/docs/markdown/globals.md +3 -2
  58. package/docs/markdown/interfaces/AppsNavigationConfig.md +12 -12
  59. package/docs/markdown/interfaces/Config.md +6 -6
  60. package/docs/markdown/interfaces/ConfigLoadOptions.md +27 -13
  61. package/docs/markdown/interfaces/LogoConfig.md +5 -5
  62. package/docs/markdown/interfaces/NavigationConfig.md +9 -9
  63. package/docs/markdown/interfaces/Oauth2Config.md +3 -3
  64. package/docs/markdown/interfaces/i18nConfig.md +4 -4
  65. package/docs/markdown/type-aliases/AnySchema.md +2 -2
  66. package/docs/markdown/type-aliases/Join.md +2 -2
  67. package/docs/markdown/type-aliases/LanguagesConfig.md +2 -2
  68. package/docs/markdown/type-aliases/Leaves.md +2 -2
  69. package/docs/markdown/type-aliases/NoInferType.md +2 -2
  70. package/docs/markdown/type-aliases/Paths.md +2 -2
  71. package/docs/markdown/variables/RXAP_CONFIG.md +2 -2
  72. package/docs/wiki/Class.ConfigLoaderService.md +6 -6
  73. package/docs/wiki/Class.ConfigService.md +21 -21
  74. package/docs/wiki/Class.ConfigTestingService.md +7 -7
  75. package/docs/wiki/Enumeration.ConfigLoadMethod.md +37 -0
  76. package/docs/wiki/Enumeration.ConfigLoadingStrategy.md +3 -3
  77. package/docs/wiki/Function.ProvideConfig.md +1 -1
  78. package/docs/wiki/Function.dnsLookup.md +1 -1
  79. package/docs/wiki/Function.dnsResolver.md +1 -1
  80. package/docs/wiki/Function.fetchCidContent.md +1 -1
  81. package/docs/wiki/Function.fetchCidContentAsJson.md +1 -1
  82. package/docs/wiki/Function.fetchCidContentViaHttp.md +1 -1
  83. package/docs/wiki/Function.fetchContentViaHttp.md +1 -1
  84. package/docs/wiki/Function.raceSuccess.md +1 -1
  85. package/docs/wiki/Interface.AppsNavigationConfig.md +11 -11
  86. package/docs/wiki/Interface.Config.md +5 -5
  87. package/docs/wiki/Interface.ConfigLoadOptions.md +26 -12
  88. package/docs/wiki/Interface.LogoConfig.md +4 -4
  89. package/docs/wiki/Interface.NavigationConfig.md +8 -8
  90. package/docs/wiki/Interface.Oauth2Config.md +2 -2
  91. package/docs/wiki/Interface.i18nConfig.md +3 -3
  92. package/docs/wiki/TypeAlias.AnySchema.md +1 -1
  93. package/docs/wiki/TypeAlias.Join.md +1 -1
  94. package/docs/wiki/TypeAlias.LanguagesConfig.md +1 -1
  95. package/docs/wiki/TypeAlias.Leaves.md +1 -1
  96. package/docs/wiki/TypeAlias.NoInferType.md +1 -1
  97. package/docs/wiki/TypeAlias.Paths.md +1 -1
  98. package/docs/wiki/Variable.RXAP_CONFIG.md +1 -1
  99. package/docs/wiki/_Sidebar.md +1 -0
  100. package/docs/wiki/globals.md +2 -1
  101. package/fesm2022/rxap-config.mjs +78 -57
  102. package/fesm2022/rxap-config.mjs.map +1 -1
  103. package/lib/config.service.d.ts +17 -0
  104. package/package.json +6 -6
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Interface: ConfigLoadOptions
4
4
 
5
- Defined in: [config.service.ts:29](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L29)
5
+ Defined in: [config.service.ts:36](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L36)
6
6
 
7
7
  ## Properties
8
8
 
@@ -10,7 +10,7 @@ Defined in: [config.service.ts:29](https://gitlab.com/rxap/packages/-/blob/5ad37
10
10
 
11
11
  > `optional` **dnsServers**: `string`[]
12
12
 
13
- Defined in: [config.service.ts:50](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L50)
13
+ Defined in: [config.service.ts:57](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L57)
14
14
 
15
15
  ***
16
16
 
@@ -18,7 +18,7 @@ Defined in: [config.service.ts:50](https://gitlab.com/rxap/packages/-/blob/5ad37
18
18
 
19
19
  > `optional` **fetchCidContent**: (`cid`, `path`?) => `Promise`\<`null` \| `Blob`\>
20
20
 
21
- Defined in: [config.service.ts:49](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L49)
21
+ Defined in: [config.service.ts:56](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L56)
22
22
 
23
23
  #### Parameters
24
24
 
@@ -40,7 +40,7 @@ Defined in: [config.service.ts:49](https://gitlab.com/rxap/packages/-/blob/5ad37
40
40
 
41
41
  > `optional` **fromCid**: `string`
42
42
 
43
- Defined in: [config.service.ts:48](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L48)
43
+ Defined in: [config.service.ts:55](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L55)
44
44
 
45
45
  Load additional configuration directly from the given Content Identifier (CID).
46
46
  This takes precedence over `fromDns` if both are provided.
@@ -51,7 +51,7 @@ This takes precedence over `fromDns` if both are provided.
51
51
 
52
52
  > `optional` **fromDns**: `string` \| `boolean`
53
53
 
54
- Defined in: [config.service.ts:43](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L43)
54
+ Defined in: [config.service.ts:50](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L50)
55
55
 
56
56
  Load additional configuration based on a CID found in a DNS TXT record.
57
57
  If true, uses `location.hostname`. If a string, uses that domain.
@@ -62,7 +62,7 @@ If true, uses `location.hostname`. If a string, uses that domain.
62
62
 
63
63
  > `optional` **fromLocalStorage**: `boolean`
64
64
 
65
- Defined in: [config.service.ts:32](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L32)
65
+ Defined in: [config.service.ts:39](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L39)
66
66
 
67
67
  ***
68
68
 
@@ -70,7 +70,7 @@ Defined in: [config.service.ts:32](https://gitlab.com/rxap/packages/-/blob/5ad37
70
70
 
71
71
  > `optional` **fromUrlParam**: `string` \| `boolean`
72
72
 
73
- Defined in: [config.service.ts:30](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L30)
73
+ Defined in: [config.service.ts:37](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L37)
74
74
 
75
75
  ***
76
76
 
@@ -78,7 +78,21 @@ Defined in: [config.service.ts:30](https://gitlab.com/rxap/packages/-/blob/5ad37
78
78
 
79
79
  > `optional` **fromUrls**: `boolean`
80
80
 
81
- Defined in: [config.service.ts:31](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L31)
81
+ Defined in: [config.service.ts:38](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L38)
82
+
83
+ ***
84
+
85
+ ### order?
86
+
87
+ > `optional` **order**: [`ConfigLoadMethod`](../wiki/Enumeration.ConfigLoadMethod)[]
88
+
89
+ Defined in: [config.service.ts:66](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L66)
90
+
91
+ Defines the order and subset of config sources to load.
92
+ If not specified, defaults to: [FROM_URLS, FROM_LOCAL_STORAGE, FROM_URL_PARAM, FROM_CID]
93
+
94
+ Note: static config is always merged first, and Overwrites are always merged last.
95
+ Note: fromDns is not a source itself - it resolves the CID for FROM_CID.
82
96
 
83
97
  ***
84
98
 
@@ -86,7 +100,7 @@ Defined in: [config.service.ts:31](https://gitlab.com/rxap/packages/-/blob/5ad37
86
100
 
87
101
  > `optional` **schema**: [`AnySchema`](../wiki/TypeAlias.AnySchema)
88
102
 
89
- Defined in: [config.service.ts:33](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L33)
103
+ Defined in: [config.service.ts:40](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L40)
90
104
 
91
105
  ***
92
106
 
@@ -94,7 +108,7 @@ Defined in: [config.service.ts:33](https://gitlab.com/rxap/packages/-/blob/5ad37
94
108
 
95
109
  > `optional` **static**: `Record`\<`string`, `any`\>
96
110
 
97
- Defined in: [config.service.ts:38](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L38)
111
+ Defined in: [config.service.ts:45](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L45)
98
112
 
99
113
  static config values
100
114
 
@@ -104,7 +118,7 @@ static config values
104
118
 
105
119
  > `optional` **strategy**: [`ConfigLoadingStrategy`](../wiki/Enumeration.ConfigLoadingStrategy)
106
120
 
107
- Defined in: [config.service.ts:51](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L51)
121
+ Defined in: [config.service.ts:58](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L58)
108
122
 
109
123
  ***
110
124
 
@@ -112,4 +126,4 @@ Defined in: [config.service.ts:51](https://gitlab.com/rxap/packages/-/blob/5ad37
112
126
 
113
127
  > `optional` **url**: `string` \| `string`[] \| (`environment`) => `string` \| `string`[]
114
128
 
115
- Defined in: [config.service.ts:34](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L34)
129
+ Defined in: [config.service.ts:41](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L41)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Interface: LogoConfig
4
4
 
5
- Defined in: [config.ts:16](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L16)
5
+ Defined in: [config.ts:16](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L16)
6
6
 
7
7
  ## Properties
8
8
 
@@ -10,7 +10,7 @@ Defined in: [config.ts:16](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
10
10
 
11
11
  > `optional` **height**: `number`
12
12
 
13
- Defined in: [config.ts:19](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L19)
13
+ Defined in: [config.ts:19](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L19)
14
14
 
15
15
  ***
16
16
 
@@ -18,7 +18,7 @@ Defined in: [config.ts:19](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
18
18
 
19
19
  > `optional` **src**: `string`
20
20
 
21
- Defined in: [config.ts:17](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L17)
21
+ Defined in: [config.ts:17](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L17)
22
22
 
23
23
  ***
24
24
 
@@ -26,4 +26,4 @@ Defined in: [config.ts:17](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
26
26
 
27
27
  > `optional` **width**: `number`
28
28
 
29
- Defined in: [config.ts:18](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L18)
29
+ Defined in: [config.ts:18](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L18)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Interface: NavigationConfig
4
4
 
5
- Defined in: [config.ts:22](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L22)
5
+ Defined in: [config.ts:22](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L22)
6
6
 
7
7
  ## Properties
8
8
 
@@ -10,7 +10,7 @@ Defined in: [config.ts:22](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
10
10
 
11
11
  > `optional` **apps**: [`AppsNavigationConfig`](../wiki/Interface.AppsNavigationConfig)[]
12
12
 
13
- Defined in: [config.ts:23](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L23)
13
+ Defined in: [config.ts:23](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L23)
14
14
 
15
15
  ***
16
16
 
@@ -18,7 +18,7 @@ Defined in: [config.ts:23](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
18
18
 
19
19
  > `optional` **collapsable**: `boolean`
20
20
 
21
- Defined in: [config.ts:24](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L24)
21
+ Defined in: [config.ts:24](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L24)
22
22
 
23
23
  ***
24
24
 
@@ -26,7 +26,7 @@ Defined in: [config.ts:24](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
26
26
 
27
27
  > `optional` **fixedInViewport**: `boolean`
28
28
 
29
- Defined in: [config.ts:28](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L28)
29
+ Defined in: [config.ts:28](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L28)
30
30
 
31
31
  ***
32
32
 
@@ -34,7 +34,7 @@ Defined in: [config.ts:28](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
34
34
 
35
35
  > `optional` **mobileQuery**: `string`
36
36
 
37
- Defined in: [config.ts:29](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L29)
37
+ Defined in: [config.ts:29](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L29)
38
38
 
39
39
  ***
40
40
 
@@ -42,7 +42,7 @@ Defined in: [config.ts:29](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
42
42
 
43
43
  > `optional` **mode**: `"side"` \| `"over"`
44
44
 
45
- Defined in: [config.ts:26](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L26)
45
+ Defined in: [config.ts:26](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L26)
46
46
 
47
47
  ***
48
48
 
@@ -50,7 +50,7 @@ Defined in: [config.ts:26](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
50
50
 
51
51
  > `optional` **opened**: `boolean`
52
52
 
53
- Defined in: [config.ts:27](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L27)
53
+ Defined in: [config.ts:27](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L27)
54
54
 
55
55
  ***
56
56
 
@@ -58,4 +58,4 @@ Defined in: [config.ts:27](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
58
58
 
59
59
  > `optional` **pinned**: `boolean`
60
60
 
61
- Defined in: [config.ts:25](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L25)
61
+ Defined in: [config.ts:25](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L25)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Interface: Oauth2Config
4
4
 
5
- Defined in: [config.ts:39](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L39)
5
+ Defined in: [config.ts:39](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L39)
6
6
 
7
7
  ## Properties
8
8
 
@@ -10,4 +10,4 @@ Defined in: [config.ts:39](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
10
10
 
11
11
  > `optional` **profileUrl**: `string`
12
12
 
13
- Defined in: [config.ts:40](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L40)
13
+ Defined in: [config.ts:40](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L40)
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Interface: i18nConfig
4
4
 
5
- Defined in: [config.ts:34](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L34)
5
+ Defined in: [config.ts:34](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L34)
6
6
 
7
7
  ## Properties
8
8
 
@@ -10,7 +10,7 @@ Defined in: [config.ts:34](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
10
10
 
11
11
  > `optional` **defaultLanguage**: `string`
12
12
 
13
- Defined in: [config.ts:36](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L36)
13
+ Defined in: [config.ts:36](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L36)
14
14
 
15
15
  ***
16
16
 
@@ -18,4 +18,4 @@ Defined in: [config.ts:36](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9
18
18
 
19
19
  > `optional` **languages**: [`LanguagesConfig`](../wiki/TypeAlias.LanguagesConfig)
20
20
 
21
- Defined in: [config.ts:35](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L35)
21
+ Defined in: [config.ts:35](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L35)
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **AnySchema**: `object`
6
6
 
7
- Defined in: [config.service.ts:22](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.service.ts#L22)
7
+ Defined in: [config.service.ts:22](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.service.ts#L22)
8
8
 
9
9
  ## Type declaration
10
10
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **Join**\<`K`, `P`\>: `K` *extends* `string` \| `number` ? `P` *extends* `string` \| `number` ? `` `${K}${"" extends P ? "" : "."}${P}` `` : `never` : `never`
6
6
 
7
- Defined in: [types.ts:8](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/types.ts#L8)
7
+ Defined in: [types.ts:8](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/types.ts#L8)
8
8
 
9
9
  ## Type Parameters
10
10
 
@@ -4,4 +4,4 @@
4
4
 
5
5
  > **LanguagesConfig**: `Record`\<`string`, `string`\>
6
6
 
7
- Defined in: [config.ts:32](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/config.ts#L32)
7
+ Defined in: [config.ts:32](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/config.ts#L32)
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **Leaves**\<`T`, `D`\>: \[`D`\] *extends* \[`never`\] ? `never` : `T` *extends* `object` ? `{ [K in keyof T]-?: Join<K, Leaves<T[K], Prev[D]>> }`\[keyof `T`\] : `""`
6
6
 
7
- Defined in: [types.ts:20](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/types.ts#L20)
7
+ Defined in: [types.ts:20](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/types.ts#L20)
8
8
 
9
9
  ## Type Parameters
10
10
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **NoInferType**\<`T`\>: \[`T`\]\[`T` *extends* `any` ? `0` : `never`\]
6
6
 
7
- Defined in: [types.ts:1](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/types.ts#L1)
7
+ Defined in: [types.ts:1](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/types.ts#L1)
8
8
 
9
9
  ## Type Parameters
10
10
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **Paths**\<`T`, `D`\>: \[`D`\] *extends* \[`never`\] ? `never` : `T` *extends* `object` ? \{ \[K in keyof T\]-?: K extends string \| number ? \`$\{K\}\` \| Join\<K, Paths\<T\[K\], Prev\[D\]\>\> : never \}\[keyof `T`\] : `""`
6
6
 
7
- Defined in: [types.ts:13](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/types.ts#L13)
7
+ Defined in: [types.ts:13](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/types.ts#L13)
8
8
 
9
9
  ## Type Parameters
10
10
 
@@ -4,4 +4,4 @@
4
4
 
5
5
  > `const` **RXAP\_CONFIG**: `InjectionToken`\<`unknown`\>
6
6
 
7
- Defined in: [tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/5ad37909a73f9e3eaab7208cdf5b0e12eb759c7e/packages/angular/config/src/lib/tokens.ts#L3)
7
+ Defined in: [tokens.ts:3](https://gitlab.com/rxap/packages/-/blob/dbb0bd2e1d3f41bc16b1a558aa71e6ef54aba7de/packages/angular/config/src/lib/tokens.ts#L3)
@@ -3,6 +3,7 @@
3
3
  ### Enumerations
4
4
 
5
5
  - [ConfigLoadingStrategy](../wiki/Enumeration.ConfigLoadingStrategy)
6
+ - [ConfigLoadMethod](../wiki/Enumeration.ConfigLoadMethod)
6
7
 
7
8
  ### Classes
8
9
 
@@ -1,8 +1,9 @@
1
- # @rxap/config v19.2.0-dev.3
1
+ # @rxap/config v19.3.0-dev.0
2
2
 
3
3
  ## Enumerations
4
4
 
5
5
  - [ConfigLoadingStrategy](../wiki/Enumeration.ConfigLoadingStrategy)
6
+ - [ConfigLoadMethod](../wiki/Enumeration.ConfigLoadMethod)
6
7
 
7
8
  ## Classes
8
9
 
@@ -206,6 +206,13 @@ var ConfigLoadingStrategy;
206
206
  ConfigLoadingStrategy["DEFAULT"] = "default";
207
207
  ConfigLoadingStrategy["FIFO"] = "fifo";
208
208
  })(ConfigLoadingStrategy || (ConfigLoadingStrategy = {}));
209
+ var ConfigLoadMethod;
210
+ (function (ConfigLoadMethod) {
211
+ ConfigLoadMethod["FROM_URLS"] = "fromUrls";
212
+ ConfigLoadMethod["FROM_LOCAL_STORAGE"] = "fromLocalStorage";
213
+ ConfigLoadMethod["FROM_URL_PARAM"] = "fromUrlParam";
214
+ ConfigLoadMethod["FROM_CID"] = "fromCid";
215
+ })(ConfigLoadMethod || (ConfigLoadMethod = {}));
209
216
  class ConfigService {
210
217
  static { this.onError = new ReplaySubject(1); }
211
218
  static { this.onRequestError = new ReplaySubject(1); }
@@ -261,86 +268,100 @@ class ConfigService {
261
268
  options.strategy = environment.config.strategy ?? options.strategy;
262
269
  }
263
270
  }
271
+ // Always merge static config first
264
272
  config = deepMerge(config, options?.static ?? {});
273
+ // Determine the order of config sources to load
274
+ const order = options.order ?? [
275
+ ConfigLoadMethod.FROM_URLS,
276
+ ConfigLoadMethod.FROM_LOCAL_STORAGE,
277
+ ConfigLoadMethod.FROM_URL_PARAM,
278
+ ConfigLoadMethod.FROM_CID,
279
+ ];
280
+ // If fromDns is enabled and FROM_CID is in the order, resolve CID first
281
+ if (options.fromDns && order.includes(ConfigLoadMethod.FROM_CID) && !options.fromCid) {
282
+ await this.loadConfigFromDns(options);
283
+ }
284
+ // Load configs from sources in the specified order
265
285
  let done = false;
266
- if (!done && options?.fromUrls !== false) {
267
- try {
268
- config = deepMerge(config, await this.loadConfigFromUrls(options, environment));
269
- if (options.strategy === ConfigLoadingStrategy.FIFO) {
270
- done = true;
271
- }
286
+ for (const method of order) {
287
+ if (done) {
288
+ break;
272
289
  }
273
- catch (error) {
274
- if (options.strategy !== ConfigLoadingStrategy.FIFO) {
275
- console.error('Could not load config from urls', error);
276
- throw error;
277
- }
278
- else {
279
- console.warn('Could not load config from urls: ' + error.message + '. Will try next strategy.');
280
- }
290
+ // Check if the source is enabled
291
+ if (!this.isSourceEnabled(options, method)) {
292
+ continue;
281
293
  }
282
- }
283
- if (!done && options?.fromLocalStorage !== false) {
284
294
  try {
285
- config = deepMerge(config, this.loadConfigFromLocalStorage(options));
286
- if (options.strategy === ConfigLoadingStrategy.FIFO) {
287
- done = true;
295
+ const loadedConfig = await this.loadConfigFromMethod(method, options, environment);
296
+ if (loadedConfig) {
297
+ config = deepMerge(config, loadedConfig);
288
298
  }
289
- }
290
- catch (error) {
291
- if (options.strategy !== ConfigLoadingStrategy.FIFO) {
292
- console.error('Could not load config from local storage', error);
293
- throw error;
294
- }
295
- else {
296
- console.warn('Could not load config from local storage: ' + error.message + '. Will try next strategy.');
297
- }
298
- }
299
- }
300
- if (!done && options?.fromUrlParam) {
301
- try {
302
- config = deepMerge(config, this.loadConfigFromUrlParam(options));
303
- if (options.strategy === ConfigLoadingStrategy.FIFO) {
304
- done = true;
305
- }
306
- }
307
- catch (error) {
308
- if (options.strategy !== ConfigLoadingStrategy.FIFO) {
309
- console.error('Could not load config from url param', error);
310
- throw error;
311
- }
312
- else {
313
- console.warn('Could not load config from url param: ' + error.message + '. Will try next strategy.');
314
- }
315
- }
316
- }
317
- if (!done && options?.fromDns) {
318
- await this.loadConfigFromDns(options);
319
- }
320
- if (!done && options?.fromCid) {
321
- try {
322
- config = deepMerge(config, await this.loadConfigFromCid(options));
299
+ // If using FIFO strategy, stop after first successful load
323
300
  if (options.strategy === ConfigLoadingStrategy.FIFO) {
324
301
  done = true;
325
302
  }
326
303
  }
327
304
  catch (error) {
305
+ const methodName = this.getMethodName(method);
328
306
  if (options.strategy !== ConfigLoadingStrategy.FIFO) {
329
- console.error('Could not load config from cid', error);
307
+ console.error(`Could not load config from ${methodName}`, error);
330
308
  throw error;
331
309
  }
332
310
  else {
333
- console.warn('Could not load config from cid: ' + error.message + '. Will try next strategy.');
311
+ console.warn(`Could not load config from ${methodName}: ${error.message}. Will try next strategy.`);
334
312
  }
335
313
  }
336
314
  }
337
- if (!done) {
315
+ if (!done && order.length > 0) {
338
316
  console.warn('No config loading strategy succeeded. Using default config.');
339
317
  }
318
+ // Always merge overwrites last
340
319
  config = deepMerge(config, this.Overwrites);
341
320
  console.debug('app config', config);
342
321
  this.Config = config;
343
322
  }
323
+ static isSourceEnabled(options, method) {
324
+ switch (method) {
325
+ case ConfigLoadMethod.FROM_URLS:
326
+ return options.fromUrls !== false;
327
+ case ConfigLoadMethod.FROM_LOCAL_STORAGE:
328
+ return options.fromLocalStorage !== false;
329
+ case ConfigLoadMethod.FROM_URL_PARAM:
330
+ return !!options.fromUrlParam;
331
+ case ConfigLoadMethod.FROM_CID:
332
+ return !!options.fromCid;
333
+ default:
334
+ return false;
335
+ }
336
+ }
337
+ static async loadConfigFromMethod(method, options, environment) {
338
+ switch (method) {
339
+ case ConfigLoadMethod.FROM_URLS:
340
+ return await this.loadConfigFromUrls(options, environment);
341
+ case ConfigLoadMethod.FROM_LOCAL_STORAGE:
342
+ return this.loadConfigFromLocalStorage(options);
343
+ case ConfigLoadMethod.FROM_URL_PARAM:
344
+ return this.loadConfigFromUrlParam(options);
345
+ case ConfigLoadMethod.FROM_CID:
346
+ return await this.loadConfigFromCid(options);
347
+ default:
348
+ return null;
349
+ }
350
+ }
351
+ static getMethodName(method) {
352
+ switch (method) {
353
+ case ConfigLoadMethod.FROM_URLS:
354
+ return 'urls';
355
+ case ConfigLoadMethod.FROM_LOCAL_STORAGE:
356
+ return 'local storage';
357
+ case ConfigLoadMethod.FROM_URL_PARAM:
358
+ return 'url param';
359
+ case ConfigLoadMethod.FROM_CID:
360
+ return 'cid';
361
+ default:
362
+ return 'unknown';
363
+ }
364
+ }
344
365
  static loadConfigFromUrlParam(options) {
345
366
  const param = typeof options.fromUrlParam === 'string' ? options.fromUrlParam : 'config';
346
367
  return this.LoadConfigDefaultFromUrlParam(param);
@@ -646,5 +667,5 @@ function ProvideConfig(config = {}) {
646
667
  * Generated bundle index. Do not edit.
647
668
  */
648
669
 
649
- export { ConfigLoaderService, ConfigLoadingStrategy, ConfigService, ConfigTestingService, ProvideConfig, RXAP_CONFIG, dnsLookup, dnsResolver, fetchCidContent, fetchCidContentAsJson, fetchCidContentViaHttp, fetchContentViaHttp, raceSuccess };
670
+ export { ConfigLoadMethod, ConfigLoaderService, ConfigLoadingStrategy, ConfigService, ConfigTestingService, ProvideConfig, RXAP_CONFIG, dnsLookup, dnsResolver, fetchCidContent, fetchCidContentAsJson, fetchCidContentViaHttp, fetchContentViaHttp, raceSuccess };
650
671
  //# sourceMappingURL=rxap-config.mjs.map