Skip to main content
Module

x/emit/mod.ts>CompilerOptions

Transpile and bundle JavaScript and TypeScript under Deno and Deno Deploy
Go to Latest
interface CompilerOptions
import { type CompilerOptions } from "https://deno.land/x/emit@0.11.0/mod.ts";

Properties

optional
checkJs: boolean
optional
emitDecoratorMetadata: boolean

Determines if reflection meta data is emitted for legacy decorators or not. Defaults to false.

optional
importsNotUsedAsValues: string
optional
inlineSourceMap: boolean

When set, instead of writing out a .js.map file to provide source maps, the source map will be embedded the source map content in the .js files.

Although this results in larger JS files, it can be convenient in some scenarios. For example, you might want to debug JS files on a webserver that doesn’t allow .map files to be served.

optional
inlineSources: boolean

When set, the original content of the .ts file as an embedded string in the source map (using the source map’s sourcesContent property).

This is often useful in the same cases as inlineSourceMap.

optional
jsx: "jsx" | "preserve"

Controls how JSX constructs are emitted in JavaScript files. This only affects output of JS files that started in .jsx or .tsx files.

optional
jsxFactory: string

Changes the function called in .js files when compiling JSX Elements using the classic JSX runtime. The most common change is to use "h" or "preact.h".

optional
jsxFragmentFactory: string

Specify the JSX fragment factory function to use when targeting react JSX emit with jsxFactory compiler option is specified, e.g. Fragment.

optional
sourceMap: boolean

Enables the generation of sourcemap files.