Module

React.Basic.DOM.Components.Ref

Package
purescript-react-basic-dom
Repository
lumihq/purescript-react-basic-dom

This module provides an efficient (no ReactDOM.findDOMNode) and declarative way to aquire a Node for an element in your render tree.

For example:

render self =
  ref \myRef ->
    case myRef of
      Nothing -> R.text "First DOM render in progress..."
      Just _  -> R.text "First DOM render complete."

#ref Source

ref :: (Maybe Node -> JSX) -> JSX

#selectorRef Source

Re-exports from Web.DOM.ParentNode