import { transpileOnly } from "https://deno.land/x/deno@v0.30.0/cli/js/deno.ts";
Takes a set of TypeScript sources and resolves with a map where the key was
the original file name provided in sources and the result contains the
source
and optionally the map
from the transpile operation. This does no
type checking and validation, it effectively "strips" the types from the
file.
const results = await Deno.transpileOnly({
"foo.ts": `const foo: string = "foo";`
});
Parameters
A map where the key is the filename and the value is the text to transpile. The filename is only used in the transpile and not resolved, for example to fill in the source name in the source map.