gka / chroma.js

JavaScript library for all kinds of color manipulations
https://gka.github.io/chroma.js/
Other
10.08k stars 543 forks source link

2.1.1 breaks partial imports #259

Closed opatut closed 1 month ago

opatut commented 3 years ago

Hello, big part of 2.0.0 changelog was this:

chroma.js has been ported from CoffeeScript to ES6! This means you can now import parts of chroma in your projects!

Which means we were all able to reduce our bundle sizes by importing directly from e.g. chroma-js/src/io/css et al and thus bundle together our own subset of chroma functionality. This was great!

Sadly, #257 and thus 2.1.1 broke that for us, due to not bundling src/ anymore. If that's by accident, please fix it quickly, this could be consiered a breaking change according to semver (since it was encouraged to "import parts", thus exposing those parts can be considered public API).

If it's by choice, I am very sad about it. I love the way I can pick the parts I need.

Edit: Suggested change: Please remove src/ from .npmignore again ;)

JakeThurman commented 3 years ago

I messaged the author on twitter to bring attention to my issue. You should make a PR and send him a link to it.

I authored #257, and I personally see no issue with including /src, I just needed to exclude /docs

gka commented 1 month ago

partial imports working in 2.5.0, again. sorry about that