babel-plugin-extract-react-types

    0.2.0 • Public • Published

    babel-plugin-extract-react-types

    A Babel plugin to store the types of React components as a property on the component for documentation

    Install

    yarn add babel-plugin-extract-react-types pretty-proptypes

    Usage

    .babelrc

    {
      "plugins": ["babel-plugin-extract-react-types"]
    }
    import SomeComponent from 'somewhere';
    import Props from 'pretty-proptypes';
    
    <Props heading="My Component" component={SomeComponent} />;

    Inspiration

    Install

    npm i babel-plugin-extract-react-types

    DownloadsWeekly Downloads

    330

    Version

    0.2.0

    License

    MIT

    Unpacked Size

    7.63 kB

    Total Files

    5

    Last publish

    Collaborators

    • noviny
    • delcore92
    • mitchellhamilton