react-here-maps icon indicating copy to clipboard operation
react-here-maps copied to clipboard

Remove dependency on bluebird and corejs

Open haimlit opened this issue 7 years ago • 2 comments

Is it possible to drop the bluebird and corejs dependencies? They weight quite a lot. react-here-maps is the project using bluebird among my dependencies, and webpack uses another version of core-js than bluebird, so I get this dependency bundled twice. I think it should be the consumer's choice if to use polyfills or not, and webpack usually fills that role sufficiently.

haimlit avatar Jul 18 '17 12:07 haimlit

Understood, I'll investigate making the changes. I believe core-js might be able to be moved to a development dependency, but bluebird might require more investigation.

Josh-ES avatar Jul 18 '17 12:07 Josh-ES

core-js in particular has cost our team a few days of issues before we determined the cause. Please either

  1. remove dependency on core-js altogether and let people polyfill as necessary
  2. import namespaced polyfills that do not affect the global scope:
import * as Map from 'core-js/library/fn/map'

In addition to preventing errors with other libraries, core-js is like 500 modules which everyone shouldn't be forced to bundle.

schtauffen avatar Sep 18 '17 15:09 schtauffen