1.1.0 • Published 7 years ago
boundless-portal v1.1.0
THIS IS AN AUTOGENERATED FILE. EDIT INDEX.JS INSTEAD.
Portal
A higher-order component for the rendering of components outside the normal React tree.
Portal
is used in other components such as Popover
to render content to places like the HTML <body>
tag, avoiding style leakage and parent layout contexts. Only accepts a single top-level child; naked text, etc will be wrapped in a <div>
.
Props
Note: only top-level props are in the README, for the full list check out the website.
Required Props
There are no required props.
Optional Props
✅ OK:
<Portal>
foo
</Portal>
<Portal>
<div>foo</div>
</Portal>
<Portal>
<div>
<div>foo</div>
<div>bar</div>
</div>
</Portal>
⛔️ Not OK:
<Portal>
<div>foo</div>
<div>bar</div>
</Portal>
```</td>
</tr>
<tr>
<td>destination</td>
<td><pre><code>HTMLElement</code></pre></td>
<td><pre><code class="language-js">document.body</code></pre></td>
<td>the location to append the generated portal and child elements</td>
</tr>
<tr>
<td>portalId</td>
<td><pre><code>string</code></pre></td>
<td><pre><code class="language-js">null</code></pre></td>
<td>the ID used to link the portal origin to the destination; added to generated `<div>` appended to the destination HTML node</td>
</tr>
</table>
1.1.0
7 years ago
1.0.4
7 years ago
1.0.3
7 years ago
1.0.2
7 years ago
1.0.1
7 years ago
1.0.0
7 years ago
1.0.0-beta.7
7 years ago
1.0.0-beta.6
7 years ago
1.0.0-beta.5
7 years ago
1.0.0-beta.4
7 years ago
1.0.0-beta.3
7 years ago