@equinor/fusion-framework-module-signalr 5.0.0 → 5.0.2

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.
@@ -1,21 +1,21 @@
1
1
  import type { IModulesConfigurator } from '@equinor/fusion-framework-module';
2
- import { SignalRModuleConfigBuilderCallback } from '../../SignalRModuleConfigurator';
2
+ import type { SignalRModuleConfigBuilderCallback } from '../../SignalRModuleConfigurator';
3
3
  import { module } from '../../SignalRModule';
4
4
  import { configureFromFramework } from './configure-from-framework';
5
5
 
6
6
  export interface enableSignalR {
7
- (
8
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
9
- configurator: IModulesConfigurator<any, any>,
10
- name: string,
11
- cb: SignalRModuleConfigBuilderCallback,
12
- ): void;
13
- (
14
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
15
- configurator: IModulesConfigurator<any, any>,
16
- name: string,
17
- options: { service: string; path: string },
18
- ): void;
7
+ (
8
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
9
+ configurator: IModulesConfigurator<any, any>,
10
+ name: string,
11
+ cb: SignalRModuleConfigBuilderCallback,
12
+ ): void;
13
+ (
14
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
15
+ configurator: IModulesConfigurator<any, any>,
16
+ name: string,
17
+ options: { service: string; path: string },
18
+ ): void;
19
19
  }
20
20
 
21
21
  /**
@@ -46,26 +46,26 @@ export interface enableSignalR {
46
46
  ```
47
47
  */
48
48
  export function enableSignalR(
49
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
50
- configurator: IModulesConfigurator<any, any>,
51
- name: string,
52
- optionsOrCallback: SignalRModuleConfigBuilderCallback | { service: string; path: string },
49
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
50
+ configurator: IModulesConfigurator<any, any>,
51
+ name: string,
52
+ optionsOrCallback: SignalRModuleConfigBuilderCallback | { service: string; path: string },
53
53
  ) {
54
- if (typeof optionsOrCallback === 'function') {
55
- configurator.addConfig({
56
- module,
57
- configure: (signalRConfigurator) => {
58
- signalRConfigurator.onCreateConfig(optionsOrCallback);
59
- },
60
- });
61
- } else {
62
- configurator.addConfig({
63
- module,
64
- configure: (signalRConfigurator) => {
65
- signalRConfigurator.onCreateConfig((builder) =>
66
- configureFromFramework({ name, ...optionsOrCallback }, builder),
67
- );
68
- },
69
- });
70
- }
54
+ if (typeof optionsOrCallback === 'function') {
55
+ configurator.addConfig({
56
+ module,
57
+ configure: (signalRConfigurator) => {
58
+ signalRConfigurator.onCreateConfig(optionsOrCallback);
59
+ },
60
+ });
61
+ } else {
62
+ configurator.addConfig({
63
+ module,
64
+ configure: (signalRConfigurator) => {
65
+ signalRConfigurator.onCreateConfig((builder) =>
66
+ configureFromFramework({ name, ...optionsOrCallback }, builder),
67
+ );
68
+ },
69
+ });
70
+ }
71
71
  }
package/src/version.ts CHANGED
@@ -1,2 +1,2 @@
1
1
  // Generated by genversion.
2
- export const version = '5.0.0';
2
+ export const version = '5.0.2';