The high order component for mounting component
npm install @rcp/hoc.mount

The high order component for mounting component
It's useful on modal component which requires should be mounted at other node (e.g. document.body) or requires single rendering instance.
``bash`
npm install @rcp/hoc.mountor use yarn
yarn add @rcp/hoc.mount
`javascript
import mount from '@rcp/hoc.mount'
const Title = mount()(({ props }) =>
ReactDOM.render(
const TitleComponent = mount({
createTimeType: 'component',
attributesGetter: ({ title }) => ({ id: title })
})(({ props }) =>
ReactDOM.render(
API
#### Options
-
createTimeType ("decorator" \| "class" \| "component") (optional, default 'class') Create mount center in which time.
-
decorator: create at calling mount() time.
- class: create at calling mount()(Component) time.
- component: create at rendering mount()(Component) time.-
mountNodeGetter ((props) => HTMLElement) (optional, default () => document.body)
- attributesGetter ((props) => any) (optional, default () => {}`)- @rcp/util.createmount - The utility for creating mountable view
This library is written and maintained by imcuttle,
MIT