@equinor/fusion-framework-app 9.1.2 → 9.1.4

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 CHANGED
@@ -1,5 +1,73 @@
1
1
  # Change Log
2
2
 
3
+ ## 9.1.4
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`736ef31`](https://github.com/equinor/fusion-framework/commit/736ef310ee101738f9022d581a2b3189b30a2646)]:
8
+ - @equinor/fusion-framework-module-event@4.2.1
9
+ - @equinor/fusion-framework@7.2.3
10
+ - @equinor/fusion-framework-module-app@5.3.8
11
+ - @equinor/fusion-framework-module-feature-flag@1.1.5
12
+
13
+ ## 9.1.3
14
+
15
+ ### Patch Changes
16
+
17
+ - [#2333](https://github.com/equinor/fusion-framework/pull/2333) [`86d55b8`](https://github.com/equinor/fusion-framework/commit/86d55b8d27a572f3f62170b1e72aceda54f955e1) Thanks [@odinr](https://github.com/odinr)! - Updated `TypeScript` to 5.5.3
18
+
19
+ - [#2320](https://github.com/equinor/fusion-framework/pull/2320) [`1dd85f3`](https://github.com/equinor/fusion-framework/commit/1dd85f3a408a73df556d1812a5f280945cc100ee) Thanks [@odinr](https://github.com/odinr)! - Removed the `removeComments` option from the `tsconfig.base.json` file.
20
+
21
+ Removing the `removeComments` option allows TypeScript to preserve comments in the compiled JavaScript output. This can be beneficial for several reasons:
22
+
23
+ 1. Improved debugging: Preserved comments can help developers understand the code better during debugging sessions.
24
+ 2. Documentation: JSDoc comments and other important code documentation will be retained in the compiled output.
25
+ 3. Source map accuracy: Keeping comments can lead to more accurate source maps, which is crucial for debugging and error tracking.
26
+
27
+ No action is required from consumers of the library. This change affects the build process and doesn't introduce any breaking changes or new features.
28
+
29
+ Before:
30
+
31
+ ```json
32
+ {
33
+ "compilerOptions": {
34
+ "module": "ES2022",
35
+ "target": "ES6",
36
+ "incremental": true,
37
+ "removeComments": true,
38
+ "preserveConstEnums": true,
39
+ "sourceMap": true,
40
+ "moduleResolution": "node"
41
+ }
42
+ }
43
+ ```
44
+
45
+ After:
46
+
47
+ ```json
48
+ {
49
+ "compilerOptions": {
50
+ "module": "ES2022",
51
+ "target": "ES6",
52
+ "incremental": true,
53
+ "preserveConstEnums": true,
54
+ "sourceMap": true,
55
+ "moduleResolution": "node"
56
+ }
57
+ }
58
+ ```
59
+
60
+ This change ensures that comments are preserved in the compiled output, potentially improving the development and debugging experience for users of the Fusion Framework.
61
+
62
+ - Updated dependencies [[`2f74edc`](https://github.com/equinor/fusion-framework/commit/2f74edcd4a3ea2b87d69f0fd63492145c3c01663), [`788d0b9`](https://github.com/equinor/fusion-framework/commit/788d0b93edc25e5b682d88c58614560c204c1af9), [`86d55b8`](https://github.com/equinor/fusion-framework/commit/86d55b8d27a572f3f62170b1e72aceda54f955e1), [`788d0b9`](https://github.com/equinor/fusion-framework/commit/788d0b93edc25e5b682d88c58614560c204c1af9), [`788d0b9`](https://github.com/equinor/fusion-framework/commit/788d0b93edc25e5b682d88c58614560c204c1af9), [`b628e90`](https://github.com/equinor/fusion-framework/commit/b628e90500b62e0185c09eb665ce31025bc9b541), [`29ff796`](https://github.com/equinor/fusion-framework/commit/29ff796ebb3a643c604e4153b6798bde5992363c), [`1dd85f3`](https://github.com/equinor/fusion-framework/commit/1dd85f3a408a73df556d1812a5f280945cc100ee)]:
63
+ - @equinor/fusion-framework-module@4.3.2
64
+ - @equinor/fusion-framework-module-http@6.0.1
65
+ - @equinor/fusion-framework-module-feature-flag@1.1.5
66
+ - @equinor/fusion-framework-module-event@4.2.0
67
+ - @equinor/fusion-framework-module-msal@3.1.2
68
+ - @equinor/fusion-framework-module-app@5.3.8
69
+ - @equinor/fusion-framework@7.2.2
70
+
3
71
  ## 9.1.2
4
72
 
5
73
  ### Patch Changes
@@ -23,7 +23,9 @@ export class AppConfigurator extends ModulesConfigurator {
23
23
  configureHttpClient(...args) {
24
24
  this.addConfig(configureHttpClient(...args));
25
25
  }
26
- useFrameworkServiceClient(serviceName, options) {
26
+ useFrameworkServiceClient(serviceName,
27
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
28
+ options) {
27
29
  this.addConfig({
28
30
  module: http,
29
31
  configure: (config, ref) => __awaiter(this, void 0, void 0, function* () {
@@ -1 +1 @@
1
- {"version":3,"file":"AppConfigurator.js","sourceRoot":"","sources":["../../src/AppConfigurator.ts"],"names":[],"mappings":";;;;;;;;;AAEA,OAAO,EAGH,mBAAmB,EACnB,mBAAmB,GACtB,MAAM,kCAAkC,CAAC;AAE1C,OAAO,KAAK,MAAM,wCAAwC,CAAC;AAE3D,OAAO,IAAI,EAAE,EACT,mBAAmB,EACnB,aAAa,GAEhB,MAAM,uCAAuC,CAAC;AAE/C,OAAO,IAAI,EAAE,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAoE5E,MAAM,OAAO,eAKT,SAAQ,mBAA+C;IAGvD,YAA4B,GAAS;QACjC,KAAK,CAAC,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;QADH,QAAG,GAAH,GAAG,CAAM;QAEjC,IAAI,CAAC,MAAM,GAAG,IAAI,mBAAmB,CAAC,iBAAiB,CAAC,CAAC;IAC7D,CAAC;IAEM,aAAa,CAAC,GAAG,IAAsC;QAC1D,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC;IAC3C,CAAC;IAEM,mBAAmB,CAAC,GAAG,IAA4C;QACtE,IAAI,CAAC,SAAS,CAAC,mBAAmB,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC;IACjD,CAAC;IAEM,yBAAyB,CAC5B,WAAmB,EAEnB,OAAmE;QAEnE,IAAI,CAAC,SAAS,CAAC;YACX,MAAM,EAAE,IAAI;YACZ,SAAS,EAAE,CAAO,MAAM,EAAE,GAAG,EAAE,EAAE;gBAC7B,MAAM,OAAO,GAAG,MAAM,CAAA,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,gBAAgB,CAA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S,CAAC,mBAAmB,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC;IACjD,CAAC;IAEM,yBAAyB,CAC5B,WAAmB;IACnB,8DAA8D;IAC9D,OAAmE;QAEnE,IAAI,CAAC,SAAS,CAAC;YACX,MAAM,EAAE,IAAI;YACZ,SAAS,EAAE,CAAO,MAAM,EAAE,GAAG,EAAE,EAAE;gBAC7B,MAAM,OAAO,GAAG,MAAM,CAAA,GAAG,aAAH,GAAG,uBAAH,GAAG,CAAE,gBAAgB,CAAC,cAAc,CAAC,WAAW,CAAC,CAAA,CAAC;gBACxE,IAAI,CAAC,OAAO,EAAE,CAAC;oBACX,MAAM,KAAK,CAAC,gCAAgC,WAAW,GAAG,CAAC,CAAC;gBAChE,CAAC;gBACD,MAAM,CAAC,eAAe,CAAC,WAAW,kCAC3B,OAAO,KACV,OAAO,EAAE,OAAO,CAAC,GAAG,EACpB,aAAa,EAAE,OAAO,CAAC,aAAa,IACtC,CAAC;YACP,CAAC,CAAA;SACJ,CAAC,CAAC;IACP,CAAC;IAEM,aAAa,CAAC,GAAG,IAAsC;QAC1D,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC;IAC3C,CAAC;CACJ;AAED,eAAe,eAAe,CAAC"}
@@ -8,13 +8,42 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
8
8
  });
9
9
  };
10
10
  import { AppConfigurator } from './AppConfigurator';
11
- export const configureModules = (cb) => (args) => __awaiter(void 0, void 0, void 0, function* () {
11
+ /**
12
+ *
13
+ * Creates a callback for initializing configuration of application modules
14
+ *
15
+ * @example
16
+ ```ts
17
+ const initialize = configureModules((configurator, args) => {
18
+ configurator.configure(someModule);
19
+ });
20
+ await initialize({ fusion, { manifest, config }});
21
+ ```
22
+ * @template TModules Addition modules
23
+ * @template TRef usually undefined, optional references
24
+ * @template TEnv environment object for configuring modules
25
+ *
26
+ * @param cb configuration callback
27
+ *
28
+ * @returns initialize function, executes configurator
29
+ */
30
+ export const configureModules = (cb) =>
31
+ /**
32
+ *
33
+ * Callback for initializing application modules
34
+ *
35
+ * @param args - Fusion and application environments (manifest, config ...)
36
+ * @returns initialized app modules
37
+ */
38
+ (args) => __awaiter(void 0, void 0, void 0, function* () {
12
39
  var _a;
13
40
  const configurator = new AppConfigurator(args.env);
14
41
  if (cb) {
15
42
  yield Promise.resolve(cb(configurator, args));
16
43
  }
17
44
  const modules = (yield configurator.initialize(args.fusion.modules));
45
+ // @eikeland
46
+ // TODO - remove check after fusion-cli is updated (app module is not enabled in fusion-cli)
18
47
  if ((_a = args.env.manifest) === null || _a === void 0 ? void 0 : _a.key) {
19
48
  modules.event.dispatchEvent('onAppModulesLoaded', {
20
49
  detail: { appKey: args.env.manifest.key, modules },
@@ -1 +1 @@
1
- {"version":3,"file":"configure-modules.js","sourceRoot":"","sources":["../../src/configure-modules.ts"],"names":[],"mappings":";;;;;;;;;AAGA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAsBpD,MAAM,CAAC,MAAM,gBAAgB,GACzB,CAKI,EAA6C,EACiC,EAAE,CAQpF,CAAO,IAAiC,EAAyC,EAAE;;IAC/E,MAAM,YAAY,GAAG,IAAI,eAAe,CAAkC,IAAI,CAAC,GAAG,CAAC,CAAC;IACpF,IAAI,EAAE,EAAE,CAAC;QACL,MAAM,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC;IAClD,CAAC;IACD,MAAM,OAAO,GAAG,CAAC,MAAM,YAAY,CAAC,UAAU,CAC1C,IAAI,CAAC,MAAM,CAAC,OAAO,CAEtB,CAA4C,CAAC;IAI9C,IAAI,MAAA,IAAI,CAAC,GAAG,CAAC,QAAQ,0CAAE,GAAG,EAAE,CAAC;QACzB,OAAO,CAAC,KAAK,CAAC,aAAa,CAAC,oBAAoB,EAAE;YAC9C,MAAM,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,EAAE,OAAO,EAAE;SACrD,CAAC,CAAC;IACP,CAAC;IACD,OAAO,OAAO,CAAC;AACnB,CAAC,CAAA,CAAC;AAEN,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"configure-modules.js","sourceRoot":"","sources":["../../src/configure-modules.ts"],"names":[],"mappings":";;;;;;;;;AAGA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAGpD;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,gBAAgB,GACzB,CAKI,EAA6C,EACiC,EAAE;AACpF;;;;;;GAMG;AACH,CAAO,IAAiC,EAAyC,EAAE;;IAC/E,MAAM,YAAY,GAAG,IAAI,eAAe,CAAkC,IAAI,CAAC,GAAG,CAAC,CAAC;IACpF,IAAI,EAAE,EAAE,CAAC;QACL,MAAM,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC;IAClD,CAAC;IACD,MAAM,OAAO,GAAG,CAAC,MAAM,YAAY,CAAC,UAAU,CAC1C,IAAI,CAAC,MAAM,CAAC,OAAO,CAEtB,CAA4C,CAAC;IAE9C,YAAY;IACZ,4FAA4F;IAC5F,IAAI,MAAA,IAAI,CAAC,GAAG,CAAC,QAAQ,0CAAE,GAAG,EAAE,CAAC;QACzB,OAAO,CAAC,KAAK,CAAC,aAAa,CAAC,oBAAoB,EAAE;YAC9C,MAAM,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,EAAE,OAAO,EAAE;SACrD,CAAC,CAAC;IACP,CAAC;IACD,OAAO,OAAO,CAAC;AACnB,CAAC,CAAA,CAAC;AAEN,eAAe,gBAAgB,CAAC"}
package/dist/esm/index.js CHANGED
@@ -1,5 +1,6 @@
1
1
  export { AppConfigurator } from './AppConfigurator';
2
2
  export * from './types';
3
3
  export { configureModules, default } from './configure-modules';
4
+ // TODO remove
4
5
  export { configureModules as initAppModules } from './configure-modules';
5
6
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAoB,MAAM,mBAAmB,CAAC;AAEtE,cAAc,SAAS,CAAC;AAExB,OAAO,EAAE,gBAAgB,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAGhE,OAAO,EAAE,gBAAgB,IAAI,cAAc,EAAE,MAAM,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAoB,MAAM,mBAAmB,CAAC;AAEtE,cAAc,SAAS,CAAC;AAExB,OAAO,EAAE,gBAAgB,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAEhE,cAAc;AACd,OAAO,EAAE,gBAAgB,IAAI,cAAc,EAAE,MAAM,qBAAqB,CAAC"}
@@ -1,2 +1,3 @@
1
- export const version = '9.1.2';
1
+ // Generated by genversion.
2
+ export const version = '9.1.4';
2
3
  //# sourceMappingURL=version.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AACA,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC"}
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC"}