https://github.com/fengkx/cjsa
Bundle commonjs package for Pure ESM modules
https://github.com/fengkx/cjsa
commonjs esm esmodules
Last synced: 4 months ago
JSON representation
Bundle commonjs package for Pure ESM modules
- Host: GitHub
- URL: https://github.com/fengkx/cjsa
- Owner: fengkx
- License: gpl-3.0
- Created: 2022-01-20T14:34:28.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2022-06-20T05:41:16.000Z (over 3 years ago)
- Last Synced: 2025-10-03T18:21:39.976Z (4 months ago)
- Topics: commonjs, esm, esmodules
- Language: JavaScript
- Homepage:
- Size: 565 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# cjsa
> Bundle commonjs package for **Pure ESM** modules
Sometime we need to use commonjs module and we also want to have an updated and well maintain commonjs package
## How it works
every original package is a submoudles in `modules` dir.
build scripts and test is located in `pacakges` dir
Inside the `packages/{{package name}}` dir, There is a `build-cjs.js` that run the build process and exports some meta data, a `package-patch.json` to generate new `package.json` using _JSON Merge Patch_ [RFC 7396 ](https://datatracker.ietf.org/doc/html/rfc7396)
Some useful internals scripts in `internals/scripts` to help maintaining this packages
After bundling the package, packages `@cjsa/*` will be published to npm. testing is enforce by using `postpack` npm script.
## Contribute
See [CONTRIBUTING.md](./CONTRIBUTING.md)
# License
Package license remains the same as the original one. But the scripts and build workflows are GPLv3 licensed.