No ES5 build on NPM?
Closed this issue · 3 comments
We've had an unexpected issue using this module in certain environments. It appears that the copy on NPM is ES6 (not ES5).
The readme states the following:
The code published to npm that gets loaded on require is in fact an ES5 transpiled version with the right shims added. This means that you can require it and use with your favourite bundler without having to adjust asset management process.
However, looking at package.json
(both the copy in this repo and the copy loaded by NPM):
"main": "src/index.js",
I was going to make a PR fixing it, but also noticed that dist/index.js
and dist/index.min.js
seem to contain template literals (haven't checked for any other ES6). Anyone know what the story is with this?
Apologies @neftaly, that is really out of date. We don't transpile to ES5 for over a year now. We do follow the LTS release schedule of Node.js and use just the features supported by the oldest LTS. With this approach, we are sure that all evergreen browsers support the feature set we use.
Updated the README to avoid misinforming users.
Thanks for clarifying that!