Skip to content

Commit f1ef4fd

Browse files
committed
Fix typo in readme
1 parent 917a2c6 commit f1ef4fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ It extra props to the InPortal (using the extra functionality we've attached to
144144
* Reverse portals tie rebuilding of the contents of the portal to InPortal (where it's defined), rather than the parent of the OutPortal (where it appears in the tree). That's great (that's the whole point really), but the contents of the InPortal will still be rebuilt anytime the InPortal itself is, e.g. if the InPortal's parent is rebuilt.
145145
* Be aware that if you call `create*PortalNode` in the render method of the parent of an InPortal, you'll get a different node to render into each time, and this will cause unnecessary rerenders, one every time the parent updates. It's generally better to create the node once and persist it, either using the useMemo hook, or in the initial construction of your class component.
146146
* By default, the types for nodes, InPortals and OutPortals allow any props and any components. Pass a component type to them to be more explicit and enforce prop types, e.g. `createHtmlPortalNode<MyComponent>`, `<portals.InPortal<MyComponent>>`, `<portals.OutPortal<MyComponent>>`.
147-
* You can pass `attributes` option for the `create*PortalNode` methods that would allow you to configure any attributes (style, class, etc.) to the intermediary div (or svg):
147+
* You can pass `attributes` option to the `create*PortalNode` methods that would allow you to configure any attributes (style, class, etc.) to the intermediary div (or svg):
148148

149149
```
150150
const portalNode = portals.createHtmlPortalNode({

0 commit comments

Comments
 (0)