A boilerplate for building React components with Rollup and publishing to npm. Version 1.1.23 requires React 16.2+, lodash 4.17+, and antd 3.1+. It provides a minimal setup with Babel transpilation and a single default export. Alternative to create-react-library and nwb.
npm install rollup-react-npmVerified import paths — ran on the pinned version, not inferred.
Basic usage: import default component from the package and render it. Note that antd CSS must be imported separately.
Migrate to a modern React component library or update the boilerplate.
Use import MyComponent from '...' instead of destructuring.
Add import 'antd/dist/antd.css' in your entry file.
Use import MyComponent from 'rollup-react-npm' (no braces).
Ensure antd CSS is imported and antd 3.x is installed.