Registry / devops / super-detype

super-detype

JSON →
library2.2.2jsnpmunverified

Super-detype is a CLI tool (v2.2.2) that converts an entire TypeScript project to JavaScript by stripping type annotations and compiling with Babel. It handles Node.js, React, Next.js, Remix, and Vite projects, but not Vue or Svelte. Unlike file-by-file converters or copy-paste tools, it processes whole directories at once. It requires Node >=22 and is primarily used via npx or global install. Release cadence is sporadic. Ships bundled TypeScript types for its own API but the tool itself generates JS.

npm install super-detype
INSTALL
IMPORT
SIG · SUPER-DETYPE
S
super-detype
devopsjavascriptv2.2.2
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
import superDetype from 'super-detype'
const superDetype = require('super-detype')
Package is ESM-only since v2.0.0. Use import syntax.
convertProject
import { convertProject } from 'super-detype'
import convertProject from 'super-detype'
convertProject is a named export. Default export is the main convert function.
CLI
npx super-detype <input> <output>
super-detype <input> <output>
Without global install, use npx. With global install, the CLI command is 'super-detype'.

Converts an entire TypeScript project at the given input path to a JavaScript project at the output path.

npx super-detype "/path/to/typescript-project" "/path/to/output"
super-detype --version
Debug
Known issues
breakingv2.0.0 removed support for CommonJS. The package is now ESM-only.
fix
Use dynamic import() or ensure your project is ESM. Do not use require().
affects: >=2.0.0
deprecatedv1.x global install usage is deprecated. Use npx or install v2 globally.
fix
Use 'npx super-detype' or install the latest globally.
affects: >=2.0.0
gotchaPaths with spaces must be quoted. On Windows, backslashes may cause issues.
fix
Wrap paths in double quotes and use forward slashes on Windows.
affects: >=1.0.0
gotchaThe output directory is completely overwritten if it exists.
fix
Always use a fresh output directory to avoid accidental data loss.
affects: >=1.0.0
Errors
Common errors & fixes
Error: Cannot find module 'super-detype'
Trying to require() the package without global install or npx.
fix
Use 'npx super-detype' or install globally with 'npm i -g super-detype'.
TypeError: super-detype is not a function
Importing default export with require in CJS context.
fix
Use ESM import or use .default with require: const superDetype = require('super-detype').default
Upgrade
Version history
2.2.2latest on npm
Audit
Dependencies
@babel/corerequiredUsed as the engine to strip TypeScript types and transpile.
@babel/preset-typescriptrequiredBabel preset required for TypeScript transform.
commanderrequiredCLI argument parsing.
fs-extrarequiredEnhanced file system operations (copy, remove).
Agent activity
2 hits · last 30 days
node
2
Resources
super-detype — npm install super-detype · libregistry