v1.2.0
Previous broken version
As was stated in #40, our current approach is broken. We've done some thinking on this in this flagpack-core discussion, but unfortunately our solution of using flagpack-core
as a dependancy to dynamically import SVG's has been proven rather troublesome.
New approach
I've suggested a new approach, that somewhat rewires the structure of our development implementations of the flagpack framework packages. Instead of using flagpack-core
as a dependancy, I've chosen to build react-flagpack
with the use of flagpack-core
. This means flagpack-core
now is a dev dependancy on required on build. There are some optimizations to be made here in the future, but for a proof of concept this should be a more robust solution.
This current approach still features dynamic imports and therefore accomplishes our goal regarding 'tree-shaking'. While the react-flagpack
may be larger in size, through the use of dynamic imports this should not increase the size of any application using react-flagpack
.
Changes
- Add
generate-flags
node script that builds the flags based onflagpack-core
- Add flag directory with flags for all sizes and values to
react-flagpack
- Moved
flagpack-core
to a dev dependancy as it's now only needed on build.