Radium v0.22.0 Release Notes
Release Date: 2018-02-09 // about 6 years ago-
๐ฅ Breaking Changes
- ๐ฆ Radium now exports defaults as
.default
, so for runtimes like Node.js for all files inlib/**
. We have changedpackage.json:main
to point to/index.js
instead of/lib/index.js
as a convenience wrapper to expose mostly what was there before so behavior ofconst Radium = require('radium');
works mostly as it did before. Caveats:- When using webpack2+ to build code with
require('radium')
in it you will need to change that to becomerequire('radium').default
. - Any imports of a default export from a file in lib like
const Enhancer = require('radium/lib/enhancer');
will need to be changed toconst Enhancer = require('radium/lib/enhancer').default;
. - We have a full examples repository of how imports work in all likely scenarios that should come up. https://github.com/FormidableLabs/radium-experiments-v0.22
- When using webpack2+ to build code with
๐ Features
- โ Add
es
ESM module export files.
๐ Fixes
- ๐ Fix
package.json:scripts.postinstall
task to correctly work for git-based dependencies.
- ๐ฆ Radium now exports defaults as