• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

optimizely / javascript-sdk / 3147 / 3
78%
master: 78%

Build:
DEFAULT BRANCH: master
Ran 20 Apr 2022 10:44PM UTC
Files 81
Run time 18s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

20 Apr 2022 10:44PM UTC coverage: 97.185%. Remained the same
SDK=javascript SDK_BRANCH=$TRAVIS_PULL_REQUEST_BRANCH

cron

travis-ci-com

GitHub
chore: Ship unminified file as ESM entrypoint (#752)

## Background

This PR is copied from [484](https://github.com/optimizely/javascript-sdk/pull/484). It was contributed by @jasonkarns a couple of years ago. I just pulled his changes, merged master and resolved conflicts.

## Summary

ESM entrypoints are very very likely to be consumed by bundlers, not loaded directly into browsers. Therefore it is preferable that the bundlers have access to the unminified source so that consumers can have more control over the final output.

~~This change _adds_ an ESM output bundle that is not minified with terser.~~ (https://github.com/optimizely/javascript-sdk/pull/477 has merged which also adds the unminified ES bundle, so this PR now just makes the unminified bundle the `module` entrypoint.)
Notably, the unminified bundle is created _in addition to_ the minified bundle;
so the minified bundle is still distributed with the package (at the same output location).

This way users who do actually want the minified bundle may still use it.

However, the `package.json#module` entrypoint is changed to reference the unminified bundle, as this is most likely what users will want when consuming from a bundler. (And bundlers are virtually the exclusive consumers of the `module` entrypoint.)

1100 of 1236 branches covered (89.0%)

Branch coverage included in aggregate %.

9638 of 9813 relevant lines covered (98.22%)

74.54 hits per line

Source Files on job 3147.3 (SDK=javascript SDK_BRANCH=$TRAVIS_PULL_REQUEST_BRANCH)
  • Tree
  • List 0
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 2290
  • Travis Job 3147.3
  • e092f81a on github
  • Prev Job for SDK=javascript SDK_BRANCH=$TRAVIS_PULL_REQUEST_BRANCH on master (#3139.3)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc