Skip to content
R

@rc-component/portal

React Portal Component

by zombiejFree

#35in UI Libraries
0In stores

Description

@rc-component/portal is a React portal primitive that renders content outside the normal component tree, into a container of your choosing,…

Highlights

  • React portal primitive with lifecycle-friendly container handling
  • getContainer prop to choose where the content renders
  • open prop to control whether content is rendered
  • autoLock prop to lock page scroll while open

Ratings & Reviews

No ratings yet

Be the first to rate @rc-component/portal.

People also visit

R

react-portal

To make your life with React Portals easier

UI Libraries
Launch
R

react-modal

Accessible modal dialog component for React

UI Libraries
Launch
R

react-relative-portal

React component for place dropdowns outside overflow: hidden; elements

UI Libraries
Launch
R

react-overlays

Utilities for creating robust overlay components

UI Libraries
Launch
F

focus-trap-react

A React component that traps focus

UI Libraries
Launch
R

react-popup

React popup component from Minutemailer

UI Libraries
Launch

@rc-component/portal FAQ

What does it do?

It renders React content into a container outside the normal tree, which overlays and modals need.

Where does it render by default?

In document.body, unless you pass getContainer.

Can it lock page scroll?

Yes. The autoLock prop locks page scroll while the portal is open.

Is it a finished modal?

No. It is a portal primitive that component authors build popups and modals on.

What are the best @rc-component/portal alternatives?

Popular alternatives to @rc-component/portal include react-portal, react-modal and react-relative-portal. See all @rc-component/portal alternatives

Developer Stuff

Badges