- Notifications
You must be signed in to change notification settings - Fork0
Example React Component, Published to npm
License
NotificationsYou must be signed in to change notification settings
navamara55/example-rollup-react-component-npm-package
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
ExampleReact
component "library" usingrollup
that is published tonpm
.
There are a lot of articles that comparerollup
andwebpack
(likethis orthis orthis orthis).
The general point is
webpack
is generally a better fit for applications, androllup
is generally a better fit for libraries1
I've never usedrollup
before - hell, I'vebarely usedwebpack
before.
This was mostly to see how easy / difficult it was to create aReact
component package usingrollup
(aka "proof-of-concept").
My requirements for this package were
- Use
babel
- Use
semantic-release
- Use
sass
- Support
umd
andes
modules - Use
storybook
- Make the exported components really simple
- Seemed pretty easy to get started with
rollup
- There area lot of plugins2
- Pretty easy to specify output types (
umd
andes
, for example) - Some
rollup
plugins didn't really play nicely withbabel@7
- which is why I downgraded to6
(I could definitely be messing something up)
- Not an easy way to plug
storybook
in- It's weird and feels kind've gross because
storybook
is usingwebpack
to build 😬
- It's weird and feels kind've gross because
- Articles that were helpful
- 1general general general general general. In general, I could do this all day.
- 2Like a metric fuck ton of plugins
- 3How I feel about "baller"
About
Example React Component, Published to npm
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
No packages published
Languages
- JavaScript98.3%
- CSS1.7%