How to use the inferno.createPortal function in inferno

To help you get started, we’ve selected a few inferno examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github infernojs / inferno / packages / inferno-create-element / __tests__ / createElement.fragment.spec.js View on Github external
render(props) {
          return createElement(
            Fragment,
            null,
            props.children,
            createPortal(createElement('div', null, 'InvisiblePortalCreator'), props.node),
            null,
            'Try out some crazy stuff'
          );
        }
      };
github infernojs / inferno / packages / inferno-extras / __tests__ / extras.spec.jsx View on Github external
render(props, state) {
          return (
            <div>
              Move It
              <div>
                <div>
                  <div>
                  <div>
                </div>
              </div>
              {createPortal(
                <div>
                  <span>
                    {[<div>, 'Okay', <span>]}
                  </span>
                  <ul>
                    <li>
                  </li></ul>
                </div>,
                secondRoot
              )}
            </span></div>
          );
        }
      }</div></div></div>
github infernojs / inferno / packages / inferno-hydrate / __tests__ / hydrate.spec.jsx View on Github external
render(props) {
            return (
              &lt;&gt;
                {props.children}
                {createPortal(<div>InvisiblePortalCreator</div>, props.node)}
                {null}
                Try out some crazy stuff
              
            );
          }
        }
github bpmn-io / dmn-js / packages / dmn-js-shared / src / components / InputSelect.js View on Github external
onInput={ this.onInput }
              onKeyDown={ this.onKeyDown }
              spellcheck="false"
              ref={ node =&gt; this.inputNode = node }
              type="text"
              value={ value } /&gt;
        }
        <span>
        </span>
        {
          optionsVisible
            &amp;&amp; createPortal(this.renderOptions(options, option), this._portalEl)
        }
      
    );
  }
}
github jhsware / inferno-bootstrap / src / Modal / Modal.js View on Github external
render() {
    return this.state._element ? createPortal(this.renderChildren(), this.state._element) : null;
  }
}