React-color: Build size & sub-components path

Created on 10 Nov 2017  路  1Comment  路  Source: casesandberg/react-color

Hello, this issue is about a bundle size. The next line from the Include the Component chapter of the readme:

import { SketchPicker } from 'react-color';
  • +120 KiB to bundle
  • +25 KiB in gzip
import SketchPicker from 'react-color/lib/components/sketch/Sketch';
  • +66 KiB
  • +11 KiB in gzip

Second variant is better, of course. But /lib/components/sketch/ it's the insides of the library. It can change in the future. I think react-color/sketch is better, is it?

Most helpful comment

Yes, you are correct! There was actually a PR merged a month ago that fixes this, it places references to the individual components in the root of lib: https://github.com/casesandberg/react-color/pull/356

>All comments

Yes, you are correct! There was actually a PR merged a month ago that fixes this, it places references to the individual components in the root of lib: https://github.com/casesandberg/react-color/pull/356

Was this page helpful?
0 / 5 - 0 ratings

Related issues

scottbarrow picture scottbarrow  路  6Comments

Glutnix picture Glutnix  路  4Comments

louh picture louh  路  4Comments

islemaster picture islemaster  路  5Comments

redguardtoo picture redguardtoo  路  4Comments