2.0.0 • Published 8 months ago
@rc-component/portal v2.0.0
rc-portal
React 18 supported Portal Component.
Development
npm install
npm start
open http://localhost:8000Feature
- React life cycle support portal component
Install
Usage
import Portal from '@rc-component/portal';
const Demo = () => {
return <Portal open>Hello World</Portal>;
};
export default Demo;🔥 API
We use typescript to create the Type definition. You can view directly in IDE. But you can still check the type definition here.
Portal
| Prop | Description | Type | Default |
|---|---|---|---|
| getContainer | Customize portal container element | Element | () => Element | document.body |
| open | Show the portal | boolean | false |
| autoLock | Lock screen scroll when open | boolean | false |
2.0.0
8 months ago
1.1.2
2 years ago
1.1.1
3 years ago
1.0.2
3 years ago
1.1.0
3 years ago
1.0.1
3 years ago
1.0.0
3 years ago
1.0.3
3 years ago
1.0.0-10
3 years ago
1.0.0-9
3 years ago
1.0.0-8
3 years ago
1.0.0-7
3 years ago
1.0.0-6
3 years ago
1.0.0-5
3 years ago
1.0.0-3
3 years ago
1.0.0-2
3 years ago
1.0.0-1
3 years ago
1.0.0-0
3 years ago
