react-render-component
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.4 • Public • Published

    React Render Component

    Tiny wrapper around React.createElement with support for dumb components and null.

    Install

    $ npm install --save react-render-component

    Usage

    import * as React from 'react';
    import renderComponent from 'react-render-component';
     
    renderComponent ( null ); // Not supported by React.createElement
    renderComponent ( <div>I'm dumb</div> ); // Not supported by React.createElement
    renderComponent ( 'a', { href: '#' }, 'link' );
    renderComponent ( () => <div>Stateless</div> );
    renderComponent ( class extends React.Component {
      render () {
        return <div>Class</div>
      }
    });

    License

    MIT © Fabio Spampinato

    Install

    npm i react-render-component

    DownloadsWeekly Downloads

    4

    Version

    1.0.4

    License

    MIT

    Unpacked Size

    5.94 kB

    Total Files

    8

    Last publish

    Collaborators

    • fabiospampinato