# tsswc

> Transpile TypeScript to JavaScript using SWC

Latest version **1.0.13** (published 2025-01-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install tsswc
pnpm add tsswc
yarn add tsswc
bun add tsswc
```

Provides the command `tsswc`.

## Health

**Score 35/100 (D)** — status: maintenance-mode.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.13 |
| Published | 2025-01-29 |
| First published | 2023-12-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 8 |
| Unpacked size | 130.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Cal Young |
| Maintainers | clyng57 |
| Keywords | typescript, swc, transpile, transpiler, compiler, transform, transformer, loader, plugin, ts, tsx, js, jsx, esm, es6 |

## Links

- npm: https://www.npmjs.com/package/tsswc
- npm.io page: https://npm.io/package/tsswc

## Dependencies (8)

- [@swc/core](https://npm.io/package/@swc/core.md) ^1.0.12
- [@swc/wasm](https://npm.io/package/@swc/wasm.md) ^1.4.6
- [typescript](https://npm.io/package/typescript.md) ^5.2.2
- [@swc/helpers](https://npm.io/package/@swc/helpers.md) ^0.5.3
- [@neumatter/slot-map](https://npm.io/package/@neumatter/slot-map.md) ^1.0.2
- [@neumatter/safe-collections](https://npm.io/package/@neumatter/safe-collections.md) ^1.0.0
- [@neumatter/swc-plugin-add-ext](https://npm.io/package/@neumatter/swc-plugin-add-ext.md) ^1.0.11
- [@swc/plugin-transform-imports](https://npm.io/package/@swc/plugin-transform-imports.md) ^1.5.94

## Alternatives

- [@mapbox/jsonlint-lines-primitives](https://npm.io/package/@mapbox/jsonlint-lines-primitives.md) — 5.3M weekly downloads
- [reftools](https://npm.io/package/reftools.md) — 3.5M weekly downloads
- [@hey-api/openapi-ts](https://npm.io/package/@hey-api/openapi-ts.md) — 3.5M weekly downloads
- [@mapbox/geojson-rewind](https://npm.io/package/@mapbox/geojson-rewind.md) — 2.4M weekly downloads
- [turbo-stream](https://npm.io/package/turbo-stream.md) — 1.7M weekly downloads

## Recent versions

- 1.0.13 (latest) — 2025-01-29
- 1.0.12 — 2025-01-29
- 1.0.11 — 2024-09-18
- 1.0.10 — 2024-09-18
- 1.0.9 — 2024-03-08
- 1.0.8 — 2023-12-28
- 1.0.7 — 2023-12-15
- 1.0.6 — 2023-12-15
- 1.0.5 — 2023-12-15
- 1.0.4 — 2023-12-15
- 1.0.3 — 2023-12-15
- 1.0.2 — 2023-12-15
- 1.0.1 — 2023-12-15
- 1.0.0 — 2023-12-15

## README

# TSSWC
[![JavaScript Style Guide](https://cdn.rawgit.com/standard/standard/master/badge.svg)](https://github.com/standard/standard)

### A library for compiling TypeScript into JavaScript using SWC.
Compiler reads from tsconfig.json.

<br />

## Table of Contents
- [ Installation ](#install)
- [ Usage ](#usage)

<br />

<a name="install"></a>
## Install

```console
npm i tsswc --save-dev
```

```console
npm i @neumatter/swc-plugin-add-ext --save-dev
```

<br />

<a name="usage"></a>
## Usage

### ./tsconfig.json:

```jsonc
{
  "$schema": "https://json.schemastore.org/tsconfig",
  "include": ["src/**/*"],
  "exclude": ["dist", ".build", "node_modules"],
  "compilerOptions": {
    "rootDir": "./src" /* Specify the root folder within your source files. */,
    "outDir": "./dist" /* Specify an output folder for all emitted files. */,
  }
}
```

### Emit declaration files:

```console
tsswc --dts
```

### Compile only:

```console
tsswc
```

### Compile & run without emitting files:

```console
node --loader=tsswc/loader.js ./test/index.ts
```

---
_Source: https://npm.io/package/tsswc · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
