jszz

raw JSON →
0.0.0 verified Fri May 01 auth: no javascript

jszz is a simple TypeScript/JSX transpiler designed for lightweight projects. As of version 0.0.0, it is in early development with no stable release or release schedule. It differentiates from established transpilers (like Babel or SWC) by aiming for minimal configuration and a smaller footprint, but lacks production readiness and community support.

error SyntaxError: Unexpected token ':'
cause TypeScript type annotations are not supported by jszz in the default configuration.
fix
Enable TypeScript mode by setting { typescript: true } in options.
error TypeError: jszz is not a function
cause Using CommonJS require() to import an ESM-only module.
fix
Use import jszz from 'jszz' or use dynamic import().
breaking The API is unstable and may change without notice in versions <1.0.0.
fix Pin to a specific version and test upgrades.
gotcha jszz does not support all TypeScript features; complex types may fail silently.
fix Check the supported features list in the documentation.
deprecated The 'compile' function is deprecated in favor of 'transform'.
fix Replace 'compile' with 'transform'.
npm install jszz
yarn add jszz
pnpm add jszz

Demonstrates basic usage of the transform function to transpile TypeScript code.

import { transform } from 'jszz';
const code = 'const x: number = 1';
const result = transform(code, { jsx: false });
console.log(result.code);