You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 15, 2025. It is now read-only.
in the most recently PR #124, the build file is consolidated into a single js file using esbuild.
Issue 1
esbuild default configuration for bundling a web application. Therefore the output is usually expected to be loaded via a script tag, not via a module system.
Consequently this package at v22 will no longer be offered in CJS module and in ESM module format.
Issue 2
package.json's main, module, exports keywords are not updated to the actual build path.
However, on a clean build, only 1 file will remain:
When that happen, this package will no longer be used with a module system (ESM / CommonJS)
Direction
I suspect this is not a desired outcome.
This issue wish to check what is the intended / desired build format for this package.
I should be available to contribute to the desired outcome too.
Possible outcome:
Combine all output file js into a single output (possible in both esbuild and rollup)
Continue to provide both CJS and ESM output (possible in rollup, may be slightly troublesome with esbuild, but can be explored)
Possible improvement
To delegate the building and publishing of the package via GitHub action - this can help ensure build is reproducible, preventing local build files from existing version to remain in published package
The text was updated successfully, but these errors were encountered:
amoshydra
changed the title
Direction for CJS / MJS support
Direction for CJS / ESM support
Dec 18, 2024
amoshydra
added a commit
to amoshydra/decimal128
that referenced
this issue
Dec 19, 2024
Hi good day!
Background
in the most recently PR #124, the build file is consolidated into a single js file using esbuild.
Issue 1
esbuild default configuration for bundling a web application. Therefore the output is usually expected to be loaded via a script tag, not via a module system.
Consequently this package at v22 will no longer be offered in CJS module and in ESM module format.
Issue 2
package.json
'smain
,module
,exports
keywords are not updated to the actual build path.Issue 3
Type declaration is no longer available
Impact
There is no issue with the latest published npm package as the existing files are not cleaned: see https://unpkg.com/browse/[email protected]/dist/
However, on a clean build, only 1 file will remain:
When that happen, this package will no longer be used with a module system (ESM / CommonJS)
Direction
I suspect this is not a desired outcome.
This issue wish to check what is the intended / desired build format for this package.
Possible outcome:
Possible improvement
To delegate the building and publishing of the package via GitHub action - this can help ensure build is reproducible, preventing local build files from existing version to remain in published package
The text was updated successfully, but these errors were encountered: