@adminide-stack/extension-api
Advanced tools
Comparing version 9.1.1-alpha.102 to 9.2.1-alpha.0
@@ -1,11 +0,12 @@ | ||
import*as React from'react';import {InversifyContext,useInjection}from'@common-stack/client-react';import {IClientContainerService}from'../interfaces/generated-models.js';const isBrowser = typeof document !== 'undefined'; | ||
import*as React from'react';import {InversifyContext}from'@common-stack/client-react';import {IClientContainerService}from'../interfaces/generated-models.js';const isBrowser = typeof document !== 'undefined'; | ||
function useExtensionController() { | ||
const { container } = React.useContext(InversifyContext); | ||
const extensionController = container.isBound(IClientContainerService.ExtensionController) | ||
? useInjection(IClientContainerService.ExtensionController) | ||
: null; | ||
if (!isBrowser) { | ||
return null; | ||
} | ||
const [extensionController, setExtensionController] = React.useState(null); | ||
React.useEffect(() => { | ||
if (isBrowser && container.isBound(IClientContainerService.ExtensionController)) { | ||
const controller = container.get(IClientContainerService.ExtensionController); | ||
setExtensionController(controller); | ||
} | ||
}, [container]); | ||
return extensionController; | ||
}export{useExtensionController}; |
{ | ||
"name": "@adminide-stack/extension-api", | ||
"version": "9.1.1-alpha.102", | ||
"version": "9.2.1-alpha.0", | ||
"description": "Workbench core for higher packages to depend on", | ||
@@ -24,3 +24,3 @@ "license": "ISC", | ||
"dependencies": { | ||
"@adminide-stack/core": "9.1.1-alpha.102", | ||
"@adminide-stack/core": "9.2.1-alpha.0", | ||
"@workbench-stack/core": "3.9.5", | ||
@@ -47,3 +47,3 @@ "abort-controller": "^3.0.0", | ||
}, | ||
"gitHead": "26771e5031febcd9f574d782f40ca38a2a9082e2" | ||
"gitHead": "51bb42d8b26d285f0381f684d0f0ca45b27675e0" | ||
} |
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
553240
12082
+ Added@adminide-stack/core@9.2.1-alpha.0(transitive)
- Removed@adminide-stack/core@9.1.1-alpha.102(transitive)