Skip to main content
Module

x/ts_transpiler/mod.ts>transpile

A standalone typescript transpiler based on deno, running in the browser
Latest
function transpile
import { transpile } from "https://deno.land/x/ts_transpiler@v0.0.2/mod.ts";

Transpiles TypeScript source code directly into JavaScript code, returning a promise which resolves with the transpiled JavaScript code.

Parameters

content: string

TypeScript module source code

optional
compilerOptions: CompilerOptions = [UNSUPPORTED]

Options to use when transpiling

Returns

Promise<string>

A promise which resolves with a string containing the transpiled JavaScript code