Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Resolves #467, #466
Description:
To support modern development, this package needs to transition from commonjs, this PR upgrades the codebase across the board to transition (builds will still output to esm and cjs).
It also upgrades a couple of dependencies that were blocked by still not being ESM, chai and p-event.
A discussion for this has been opened up here: #477
Type of change:
Why is this change required?:
In order to still be able to update dependencies while supporting and using modern development practices.
Code changes:
type
to the two dist foldersES2021
, Microsoft says this config should be good to support Node 16: https://github.com/microsoft/TypeScript/wiki/Node-Target-Mapping#node-16node:
and.js
./dist/esm
,./dist/cjs
and./dist/types
For ESM and base:
Node16
For CJS:
Retains the current config