create-react-library
create-react-library copied to clipboard
Building Modular Libraries
I want to build modular libraries.
This issue is a good description for my problem. https://github.com/transitive-bullshit/create-react-library/issues/63
Unfortunately it was ended because v3 changes CRL . Does anyone have a current example or guidance on how to achieve this goal?
Can you add an example rollup configuration for building modular libraries?
For example:
Multiple imports Right Now-
import { A, B } from 'package';With Modular Imports -
import A from 'package/A'; import B from 'package/B';^ This approach helps reduce the bundle size, as only the file needed is imported and added to the bundle.
Closing as out of date since the
v3release changes nearly everything about CRL.
Is there any way to achieve what was being discussed in
v3?
Seconded! I'm working on an icon library that absolutely needs tree-shaking to avoid catastrophic bundle bloat -- hundreds of SVGs when you only need two or three is a non-starter. For now it seems the best course of action is to use v2?