Comparing version 0.1.2 to 0.1.3
@@ -5,2 +5,4 @@ # Changelog | ||
### [0.1.3](https://github.com/nuxt-contrib/jiti/compare/v0.1.2...v0.1.3) (2020-06-07) | ||
### [0.1.2](https://github.com/nuxt-contrib/jiti/compare/v0.1.1...v0.1.2) (2020-06-07) | ||
@@ -7,0 +9,0 @@ |
{ | ||
"name": "jiti", | ||
"version": "0.1.2", | ||
"description": "", | ||
"version": "0.1.3", | ||
"description": "Runtime typescript and ESM support for Node.js (CommonJS)", | ||
"license": "MIT", | ||
@@ -6,0 +6,0 @@ "main": "dist/jiti.js", |
# jiti | ||
Just-in-time compiler for typescript and esm files for CommonJS environments. | ||
> Runtime typescript and ESM support for Node.js (CommonJS) | ||
[![version][npm-v-src]][npm-v-href] | ||
[![downloads][npm-d-src]][npm-d-href] | ||
[![size][size-src]][size-href] | ||
## Features | ||
- Stable typescript and esm syntax support (currently using babel) | ||
- Provide sync interface to replace `require()` and `esm()` | ||
- Super slim and zero dependency (~1M install size) | ||
- Stable typescript and esm syntax support | ||
- Provide sync interface to replace require | ||
- Super slim and zero dependency | ||
- Syntax detect to avoid extra transform | ||
@@ -21,2 +25,39 @@ - CommonJS cache integration | ||
## Compared to Alternatives | ||
### [`standard-things/esm`](https://github.com/standard-things/esm) | ||
- `+` Much more stable thanks to babel | ||
- `+` Less low level operations | ||
- `+` Typescript support | ||
- `-` Slower | ||
- `-` No source-map support at the moment | ||
### [`babel-register`](https://babeljs.io/docs/en/babel-register) | ||
- `+` Smaller install size (~1M vs ~11M with same plugins) | ||
- `+` Configured out of the box | ||
- `+` Smart syntax detect to avoid unnecessary trnaspilation | ||
- `+` Does not ignores `node_modules`. ESM everywhere yay! | ||
- `+` Embeddable | ||
### [`esbuild`](https://github.com/evanw/esbuild) | ||
- `+` No native dependency | ||
- `+` More stable thanks to babel | ||
- `-` Slower | ||
- `+` Embeddable | ||
### `ts-node` | ||
- `+` Support both esm and typescript | ||
- `/` No typechecking support / Faster | ||
- `+` Smart syntax detect to avoid unnecessary trnaspilation | ||
### Bundlers (`rollup`, `webpack`, `snowpack`, etc) | ||
Meanwhile it would be much better making an optimized bundle to deploy to production or as npm package, using bundler setup and watching is frustrating during project development that's where `jiti` (or similar tools like `ts-node`) would be more convenient. | ||
**Note:** However currently only babel transform is supported, configurable transform support is in the roadmap so using `esbuild` or other solutions would be possible. | ||
## Development | ||
@@ -42,2 +83,15 @@ | ||
MIT | ||
MIT. Made with 💖 | ||
<!-- Refs --> | ||
[npm-v-src]: https://img.shields.io/npm/v/jiti?style=flat-square | ||
[npm-v-href]: https://npmjs.com/package/jiti | ||
[npm-d-src]: https://img.shields.io/npm/dm/jiti?style=flat-square | ||
[npm-d-href]: https://npmjs.com/package/jiti | ||
[github-actions-src]: https://img.shields.io/github/workflow/status/nuxt-contrib/jiti/ci/master?style=flat-square | ||
[github-actions-href]: https://github.com/nuxt-contrib/jiti/actions?query=workflow%3Aci | ||
[size-src]: https://packagephobia.now.sh/badge?p=jiti | ||
[size-href]: https://packagephobia.now.sh/result?p=jiti |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
1138875
96
0