@equinor/fusion-framework
Advanced tools
Comparing version 3.0.2 to 4.0.0-alpha.0
@@ -6,2 +6,20 @@ # Change Log | ||
## [4.0.0-alpha.0](https://github.com/equinor/fusion-framework/compare/@equinor/fusion-framework@3.0.2...@equinor/fusion-framework@4.0.0-alpha.0) (2022-09-12) | ||
### ⚠ BREAKING CHANGES | ||
* **framework:** initialize now takes object | ||
### Features | ||
* **framework:** rewrite configurator ([eda8fbf](https://github.com/equinor/fusion-framework/commit/eda8fbf2cb83e839a798063e15dc185801e6c17b)) | ||
### Bug Fixes | ||
* **framework:** add default modules ([190271b](https://github.com/equinor/fusion-framework/commit/190271b0ed4a4c3c876cbed0de3ec48cd8004fdc)) | ||
## 3.0.2 (2022-09-05) | ||
@@ -8,0 +26,0 @@ |
@@ -1,12 +0,4 @@ | ||
import { initializeFusionModules } from './modules'; | ||
export const initFusion = async (init, additionalModules) => { | ||
const modules = await initializeFusionModules(init, additionalModules); | ||
const fusion = { | ||
modules, | ||
}; | ||
window.Fusion = fusion; | ||
modules.event.dispatchEvent('onFrameworkLoaded', { detail: fusion }); | ||
return fusion; | ||
}; | ||
export default initFusion; | ||
export { FusionConfigurator } from './configurator'; | ||
export * from './types'; | ||
export { default, init } from './init'; | ||
//# sourceMappingURL=index.js.map |
@@ -1,11 +0,3 @@ | ||
import { AnyModule } from '@equinor/fusion-framework-module'; | ||
import { FrameworkEvent, FrameworkEventInit } from '@equinor/fusion-framework-module-event'; | ||
import { FusionConfigurator, FusionModulesInstance } from './modules'; | ||
export type { FusionConfigurator, FusionModules } from './modules'; | ||
export interface AppManifest { | ||
} | ||
export interface Fusion<TModules extends Array<AnyModule> = Array<AnyModule>> { | ||
modules: FusionModulesInstance<TModules>; | ||
} | ||
export declare const initFusion: <TModules extends AnyModule[] = AnyModule[]>(init: FusionConfigurator<TModules>, additionalModules?: TModules | undefined) => Promise<Fusion<TModules>>; | ||
import type { Fusion } from './types'; | ||
declare module '@equinor/fusion-framework-module-event' { | ||
@@ -21,2 +13,4 @@ interface FrameworkEventMap { | ||
} | ||
export default initFusion; | ||
export { FusionConfigurator } from './configurator'; | ||
export * from './types'; | ||
export { default, init } from './init'; |
{ | ||
"name": "@equinor/fusion-framework", | ||
"version": "3.0.2", | ||
"version": "4.0.0-alpha.0", | ||
"description": "", | ||
@@ -26,7 +26,7 @@ "main": "dist/esm/index.js", | ||
"dependencies": { | ||
"@equinor/fusion-framework-module": "^0.4.4", | ||
"@equinor/fusion-framework-module-event": "^0.1.4", | ||
"@equinor/fusion-framework-module-http": "^1.0.2", | ||
"@equinor/fusion-framework-module-msal": "^0.4.2", | ||
"@equinor/fusion-framework-module-service-discovery": "^0.7.2", | ||
"@equinor/fusion-framework-module": "^1.0.0-alpha.0", | ||
"@equinor/fusion-framework-module-event": "^1.0.0-alpha.0", | ||
"@equinor/fusion-framework-module-http": "^2.0.0-alpha.0", | ||
"@equinor/fusion-framework-module-msal": "^1.0.0-alpha.0", | ||
"@equinor/fusion-framework-module-service-discovery": "^1.0.0-alpha.0", | ||
"rxjs": "^7.5.6" | ||
@@ -37,3 +37,3 @@ }, | ||
}, | ||
"gitHead": "512e05eab757da7a9836199dd28a1bc0dbf5b492" | ||
"gitHead": "c077f3a9bda113b739faca7bb3fc1e96c2b8dc77" | ||
} |
@@ -1,39 +0,4 @@ | ||
/* eslint-disable @typescript-eslint/no-empty-interface */ | ||
import { AnyModule } from '@equinor/fusion-framework-module'; | ||
import { FrameworkEvent, FrameworkEventInit } from '@equinor/fusion-framework-module-event'; | ||
import { FusionConfigurator, FusionModulesInstance, initializeFusionModules } from './modules'; | ||
import type { Fusion } from './types'; | ||
export type { FusionConfigurator, FusionModules } from './modules'; | ||
export interface AppManifest {} | ||
export interface Fusion<TModules extends Array<AnyModule> = Array<AnyModule>> { | ||
/** | ||
* Configured services for Fusion | ||
*/ | ||
modules: FusionModulesInstance<TModules>; | ||
/** | ||
* Create a scoped instance of services | ||
*/ | ||
// createInstance: <TModule extends Module<any, any>>( | ||
// configurator: ModulesConfigurator, | ||
// modules: TModule[] | ||
// ) => Promise<ModuleType<Modules>>; | ||
} | ||
export const initFusion = async <TModules extends Array<AnyModule> = Array<AnyModule>>( | ||
init: FusionConfigurator<TModules>, | ||
additionalModules?: TModules | ||
): Promise<Fusion<TModules>> => { | ||
const modules = await initializeFusionModules(init, additionalModules); | ||
const fusion = { | ||
modules, | ||
}; | ||
window.Fusion = fusion; | ||
modules.event.dispatchEvent('onFrameworkLoaded', { detail: fusion }); | ||
return fusion; | ||
}; | ||
declare module '@equinor/fusion-framework-module-event' { | ||
@@ -51,2 +16,5 @@ interface FrameworkEventMap { | ||
export default initFusion; | ||
export { FusionConfigurator } from './configurator'; | ||
export * from './types'; | ||
export { default, init } from './init'; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
116940
23
251
2
1
+ Added@equinor/fusion-framework-module@1.3.0(transitive)
+ Added@equinor/fusion-framework-module-event@1.2.1(transitive)
+ Added@equinor/fusion-framework-module-http@2.2.3(transitive)
+ Added@equinor/fusion-framework-module-msal@1.0.23(transitive)
+ Added@equinor/fusion-framework-module-service-discovery@1.0.7(transitive)
- Removed@equinor/fusion-framework-module@0.4.4(transitive)
- Removed@equinor/fusion-framework-module-event@0.1.4(transitive)
- Removed@equinor/fusion-framework-module-http@1.0.2(transitive)
- Removed@equinor/fusion-framework-module-msal@0.4.2(transitive)
- Removed@equinor/fusion-framework-module-service-discovery@0.7.2(transitive)
Updated@equinor/fusion-framework-module-event@^1.0.0-alpha.0
Updated@equinor/fusion-framework-module-service-discovery@^1.0.0-alpha.0