Skip to content

Conversation

privatenumber
Copy link
Contributor

@privatenumber privatenumber commented Aug 3, 2022

Problem

The ESM migration from #35 is a breaking change (which warrants a major version bump).

This is an intrusive change since all dependent projects will also have to convert to ESM or use a bundler.

Changes

  • Revert default package type to CommonJS
  • Use pkgroll (bundler) to create a CommonJS and ESM distribution. This allows for the ESM source-code and distribution without forcing dependents to use ESM or a bundler.
  • Since normalize-url is an ESM dependency, it's bundled in so that it can also be used in the CJS distribution. This way, we can always pull the latest changes from normalize-url without being stuck on an older version that get no updates.

Other info

Also created another PR improving the regular expression: privatenumber#1

@IonicaBizau IonicaBizau mentioned this pull request Aug 3, 2022
@IonicaBizau IonicaBizau merged commit 8f0dfd7 into IonicaBizau:master Aug 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants