@rhc-shared-components/control-wrapper
v1.0.0
Published
A wrapper for RHC applications to provide them control context like permissions and maintenance banners
Downloads
54
Keywords
Readme
@rhc-shared-components/control-wrapper
project description
Install
npm install --save @rhc-shared-components/control-wrapper
Usage
import React from 'react';
import { ControllerContext, ControllerContextProvider } from '@rhc-shared-components/control-wrapper';
export const Example =(props) => {
return <ControllerContextProvider><YourComponent /></ControllerContextProvider>;
}
export const YourComponent = (props) => {
const controlData = React.useContext(ControllerContext);
}
License
MIT © authorGithubUsername