@equinor/fusion
Advanced tools
Comparing version 0.1.37 to 0.1.38
@@ -16,3 +16,13 @@ import { createContext, useContext } from "react"; | ||
}; | ||
const FusionContext = createContext({}); | ||
const ensureGlobalFusionContextType = () => { | ||
const win = window; | ||
const key = "EQUINOR_FUSION_CONTEXT"; | ||
if (typeof win[key] !== undefined && win[key]) { | ||
return win[key]; | ||
} | ||
const fusionContext = createContext({}); | ||
win[key] = fusionContext; | ||
return fusionContext; | ||
}; | ||
const FusionContext = ensureGlobalFusionContextType(); | ||
export const createFusionContext = (authContainer, serviceResolver, refs, options) => { | ||
@@ -19,0 +29,0 @@ const abortControllerManager = new AbortControllerManager(); |
{ | ||
"name": "@equinor/fusion", | ||
"version": "0.1.37", | ||
"version": "0.1.38", | ||
"description": "Everything a Fusion app needs to communicate with the core", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
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
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
112512
2593