Logo

2.0 Migration Guide

Breaking changes

Core-js dependency removal and theoretical drop compatibility for node below 10

In #569 We removed core-js dependency.

It should not effectively affect your users or build pipelines. But it was technically a breaking change.

We set babel preset that makes all non-browser dependencies compatible with node from version 10. But previous setup was using browser env so If you was able to build Linaria with previous versions of node, it should work also now. Support for browsers environment didn't change.

After that you should be able to solve issues with core-js dependency in your project, because it will no longer collide with version used by Linaria.

The default evaluation strategy has been changed to shaker

It should not affect existed code since the new strategy is more powerful, but you can always switch to the old one by adding the next rules section to your Linaria-config:

  [
    {
      action: require('linaria/evaluators').extractor,
    },
    {
      test: /\/node_modules\//,
      action: 'ignore',
    },
  ]