packages/docs/src/routes/api/qwik-optimizer/index.mdx
basename(path: string, ext?: string): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> <tr><td>ext
</td><td>string
</td><td>(Optional)
</td></tr> </tbody></table>Returns:
string
<h2 id="bundlegraphadder">BundleGraphAdder</h2>A function that returns a map of bundle names to their dependencies.
export type BundleGraphAdder = (manifest: QwikManifest) => Record<
string,
{
imports?: string[];
dynamicImports?: string[];
}
>;
References: QwikManifest
<h2 id="componententrystrategy">ComponentEntryStrategy</h2>export interface ComponentEntryStrategy
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>Record<string, string>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>'component'
</td><td> </td></tr> </tbody></table> <h2 id="createoptimizer">createOptimizer</h2>createOptimizer: (optimizerOptions?: OptimizerOptions) => Promise<Optimizer>;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>optimizerOptions
</td><td> </td><td>(Optional)
</td></tr> </tbody></table>Returns:
Promise<Optimizer>
<h2 id="diagnostic">Diagnostic</h2>export interface Diagnostic
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string[] | null
</td><td> </td></tr> </tbody></table> <h2 id="diagnosticcategory">DiagnosticCategory</h2>export type DiagnosticCategory = "error" | "warning" | "sourceError";
dirname(path: string): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="experimentalfeatures-enablerequestrewrite">enableRequestRewrite</h2> <h2 id="entrystrategy">EntryStrategy</h2>export type EntryStrategy =
| InlineEntryStrategy
| HoistEntryStrategy
| SingleEntryStrategy
| HookEntryStrategy
| SegmentEntryStrategy
| ComponentEntryStrategy
| SmartEntryStrategy;
References: InlineEntryStrategy, SingleEntryStrategy, SegmentEntryStrategy, ComponentEntryStrategy, SmartEntryStrategy
<h2 id="experimentalfeatures">ExperimentalFeatures</h2>This API is provided as an alpha preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Use __EXPERIMENTAL__.x to check if feature x is enabled. It will be replaced with true or false via an exact string replacement.
Add experimental features to this enum definition.
export declare enum ExperimentalFeatures
Member
</th><th>Value
</th><th>Description
</th></tr></thead> <tbody><tr><td>enableRequestRewrite
</td><td>"enableRequestRewrite"
(ALPHA) Enable request.rewrite()
</td></tr> <tr><td>noSPA
</td><td>"noSPA"
(ALPHA) Disable SPA navigation handler in Qwik City
</td></tr> <tr><td>preventNavigate
</td><td>"preventNavigate"
(ALPHA) Enable the usePreventNavigate hook
</td></tr> <tr><td>valibot
</td><td>"valibot"
(ALPHA) Enable the Valibot form validation
</td></tr> </tbody></table> <h2 id="path-extname">extname</h2>extname(path: string): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="path-format">format</h2>format(pathObject: {
root: string;
dir: string;
base: string;
ext: string;
name: string;
}): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>pathObject
</td><td>{ root: string; dir: string; base: string; ext: string; name: string; }
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="globalinjections">GlobalInjections</h2>export interface GlobalInjections
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>{ [key: string]: string; }
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>'head' | 'body'
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> </tbody></table> <h2 id="inlineentrystrategy">InlineEntryStrategy</h2>export interface InlineEntryStrategy
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>'inline'
</td><td> </td></tr> </tbody></table> <h2 id="path-isabsolute">isAbsolute</h2>isAbsolute(path: string): boolean;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
boolean
<h2 id="path-join">join</h2>join(...paths: string[]): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>paths
</td><td>string[]
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="minifymode">MinifyMode</h2>export type MinifyMode = "simplify" | "none";
normalize(path: string): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="experimentalfeatures-nospa">noSPA</h2> <h2 id="optimizer">Optimizer</h2>export interface Optimizer
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td>Optimizer system use. This can be updated with a custom file system.
</td></tr> </tbody></table> <table><thead><tr><th>Method
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td>Transforms the directory from the file system.
</td></tr> <tr><td> </td><td>Transforms the directory from the file system.
</td></tr> <tr><td> </td><td>Transforms the input code string, does not access the file system.
</td></tr> <tr><td> </td><td>Transforms the input code string, does not access the file system.
</td></tr> </tbody></table> <h2 id="optimizeroptions">OptimizerOptions</h2>export interface OptimizerOptions
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>any
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>number
</td><td>(Optional) Inline the global styles if they're smaller than this
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional) Enable sourcemaps
</td></tr> <tr><td> </td><td> </td><td> </td><td>(Optional)
</td></tr> </tbody></table> <h2 id="optimizersystem">OptimizerSystem</h2>export interface OptimizerSystem
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>() => string
</td><td> </td></tr> <tr><td> </td><td> </td><td>(path: string) => Promise<any>
</td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td>(rootDir: string) => Promise<TransformModuleInput[]>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td>(path: string) => Promise<any>
</td><td> </td></tr> </tbody></table> <h2 id="path-parse">parse</h2>parse(path: string): {
root: string;
dir: string;
base: string;
ext: string;
name: string;
};
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>path
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
{ root: string; dir: string; base: string; ext: string; name: string; }
<h2 id="path">Path</h2>export interface Path
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td>readonly
string
</td><td> </td></tr> <tr><td> </td><td>readonly
readonly
string
</td><td> </td></tr> <tr><td> </td><td>readonly
null
</td><td> </td></tr> </tbody></table> <table><thead><tr><th>Method
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> <tr><td> </td><td> </td></tr> </tbody></table> <h2 id="experimentalfeatures-preventnavigate">preventNavigate</h2> <h2 id="qwikasset">QwikAsset</h2>export interface QwikAsset
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string | undefined
</td><td>Name of the asset
</td></tr> <tr><td> </td><td> </td><td>number
</td><td>Size of the asset
</td></tr> </tbody></table> <h2 id="qwikbuildmode">QwikBuildMode</h2>export type QwikBuildMode = "production" | "development";
export type QwikBuildTarget = "client" | "ssr" | "lib" | "test";
export interface QwikBundle
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string[]
</td><td>(Optional) Dynamic imports
</td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional) Direct imports
</td></tr> <tr><td> </td><td> </td><td>number
</td><td>(Optional) Interactivity score of the bundle
</td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional) Source files of the bundle
</td></tr> <tr><td> </td><td> </td><td>number
</td><td>Size of the bundle
</td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional) Symbols in the bundle
</td></tr> <tr><td> </td><td> </td><td>number
</td><td>Total size of this bundle's static import graph
</td></tr> </tbody></table> <h2 id="qwikbundlegraph">QwikBundleGraph</h2>Bundle graph.
Format: [ 'bundle-a.js', 3, 5 // Depends on 'bundle-b.js' and 'bundle-c.js' 'bundle-b.js', 5, // Depends on 'bundle-c.js' 'bundle-c.js', ]
export type QwikBundleGraph = Array<string | number>;
The metadata of the build. One of its uses is storing where QRL symbols are located.
export interface QwikManifest
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>{ [fileName: string]: QwikAsset; }
</td><td>(Optional) All assets. The key is the fileName relative to the rootDir
</td></tr> <tr><td> </td><td> </td><td> </td><td>(Optional) All bundles in a compact graph format with probabilities
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional) The bundle graph fileName
</td></tr> <tr><td> </td><td> </td><td>{ [fileName: string]: QwikBundle; }
</td><td>All code bundles, used to know the import graph. The key is the bundle fileName relative to "build/"
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional) The Qwik core bundle fileName
</td></tr> <tr><td> </td><td> </td><td> </td><td>(Optional) CSS etc to inject in the document head
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>Content hash of the manifest, if this changes, the code changed
</td></tr> <tr><td> </td><td> </td><td>{ [symbolName: string]: string; }
</td><td>Where QRLs are located. The key is the symbol name, the value is the bundle fileName
</td></tr> <tr><td> </td><td> </td><td>{ target?: string; buildMode?: string; entryStrategy?: { type: EntryStrategy['type']; }; }
</td><td>(Optional) The options used to build the manifest
</td></tr> <tr><td> </td><td> </td><td>{ [name: string]: string; }
</td><td>(Optional) The platform used to build the manifest
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional) The preloader bundle fileName
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional) The Qwik loader bundle fileName
</td></tr> <tr><td> </td><td> </td><td>{ [symbolName: string]: QwikSymbol; }
</td><td>QRL symbols
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>The version of the manifest
</td></tr> </tbody></table> <h2 id="qwikrollup">qwikRollup</h2>export declare function qwikRollup(
qwikRollupOpts?: QwikRollupPluginOptions,
): any;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>qwikRollupOpts
</td><td> </td><td>(Optional)
</td></tr> </tbody></table>Returns:
any
<h2 id="qwikrolluppluginoptions">QwikRollupPluginOptions</h2>export interface QwikRollupPluginOptions
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td>(Optional) Build production or development.
Default development
boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional) Prints verbose Qwik plugin debug logs.
Default false
(Optional) The Qwik entry strategy to use while building for production. During development the type is always segment.
Default { type: "smart" })
(keyof typeof ExperimentalFeatures)[]
</td><td>(Optional) Experimental features. These can come and go in patch releases, and their API is not guaranteed to be stable between releases.
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional) Run eslint on the source files for the ssr build or dev server. This can slow down startup on large projects. Defaults to true
(Optional) The SSR build requires the manifest generated during the client build. The manifestInput option can be used to manually provide a manifest.
Default undefined
(manifest: QwikManifest) => Promise<void> | void
</td><td>(Optional) The client build will create a manifest and this hook is called with the generated build data.
Default undefined
(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional) The root of the application, which is commonly the same directory as package.json and rollup.config.js.
Default process.cwd()
string
</td><td>(Optional) The source directory to find all the Qwik components. Since Qwik does not have a single input, the srcDir is used to recursively find Qwik files.
Default src
TransformModuleInput[] | null
</td><td>(Optional) Alternative to srcDir, where srcInputs is able to provide the files manually. This option is useful for an environment without a file system, such as a webworker.
Default: null
(Optional) Target client or ssr.
Default client
((transformedModules: TransformModule[]) => Promise<void> | void) | null
</td><td>(Optional) Hook that's called after the build and provides all of the transformed modules that were used before bundling.
</td></tr> </tbody></table> <h2 id="qwiksymbol">QwikSymbol</h2>export interface QwikSymbol
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>boolean
</td><td> </td></tr> <tr><td> </td><td> </td><td>'function' | 'eventHandler'
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>[number, number]
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> </tbody></table> <h2 id="qwikvite">qwikVite</h2>The types for Vite/Rollup don't allow us to be too specific about the return type. The correct return type is [QwikVitePlugin, VitePlugin<never>], and if you search the plugin by name you'll get the QwikVitePlugin.
export declare function qwikVite(qwikViteOpts?: QwikVitePluginOptions): any;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>qwikViteOpts
</td><td> </td><td>(Optional)
</td></tr> </tbody></table>Returns:
any
<h2 id="qwikvitedevresponse">QwikViteDevResponse</h2>export interface QwikViteDevResponse
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>Record<string, any>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>() => void
</td><td>(Optional)
</td></tr> </tbody></table> <h2 id="qwikviteplugin">QwikVitePlugin</h2>This is the type of the "pre" Qwik Vite plugin. qwikVite actually returns a tuple of two plugins, but after Vite flattens them, you can find the plugin by name.
export type QwikVitePlugin = P<QwikVitePluginApi> & {
name: "vite-plugin-qwik";
};
References: QwikVitePluginApi
<h2 id="qwikvitepluginapi">QwikVitePluginApi</h2>export interface QwikVitePluginApi
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>() => string | undefined
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => QwikManifest | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => Optimizer | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => NormalizedQwikPluginOptions
</td><td> </td></tr> <tr><td> </td><td> </td><td>() => string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>(adder: BundleGraphAdder) => void
</td><td> </td></tr> </tbody></table> <h2 id="qwikvitepluginoptions">QwikVitePluginOptions</h2>export type QwikVitePluginOptions =
| QwikVitePluginCSROptions
| QwikVitePluginSSROptions;
relative(from: string, to: string): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>from
</td><td>string
</td><td> </td></tr> <tr><td>to
</td><td>string
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="path-resolve">resolve</h2>resolve(...paths: string[]): string;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>paths
</td><td>string[]
</td><td> </td></tr> </tbody></table>Returns:
string
<h2 id="resolvedmanifest">ResolvedManifest</h2>export interface ResolvedManifest
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> </tbody></table> <h2 id="segmentanalysis">SegmentAnalysis</h2>export interface SegmentAnalysis
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>boolean
</td><td> </td></tr> <tr><td> </td><td> </td><td>'eventHandler' | 'function'
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>[number, number]
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> </tbody></table> <h2 id="segmententrystrategy">SegmentEntryStrategy</h2>export interface SegmentEntryStrategy
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>Record<string, string>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>'segment'
</td><td> </td></tr> </tbody></table> <h2 id="serverqwikmanifest">ServerQwikManifest</h2>The manifest values that are needed for SSR.
export type ServerQwikManifest = Pick<
QwikManifest,
| "manifestHash"
| "injections"
| "bundleGraph"
| "bundleGraphAsset"
| "mapping"
| "preloader"
| "core"
| "qwikLoader"
>;
References: QwikManifest
<h2 id="singleentrystrategy">SingleEntryStrategy</h2>export interface SingleEntryStrategy
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>Record<string, string>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>'single'
</td><td> </td></tr> </tbody></table> <h2 id="smartentrystrategy">SmartEntryStrategy</h2>export interface SmartEntryStrategy
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>Record<string, string>
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>'smart'
</td><td> </td></tr> </tbody></table> <h2 id="sourcelocation">SourceLocation</h2>export interface SourceLocation
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>number
</td><td> </td></tr> <tr><td> </td><td> </td><td>number
</td><td> </td></tr> <tr><td> </td><td> </td><td>number
</td><td> </td></tr> <tr><td> </td><td> </td><td>number
</td><td> </td></tr> <tr><td> </td><td> </td><td>number
</td><td> </td></tr> <tr><td> </td><td> </td><td>number
</td><td> </td></tr> </tbody></table> <h2 id="sourcemapsoption">SourceMapsOption</h2>export type SourceMapsOption = "external" | "inline" | undefined | null;
This API is provided as an alpha preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
For a given symbol (QRL such as onKeydown$) the server needs to know which bundle the symbol is in.
Normally this is provided by Qwik's q-manifest . But q-manifest only exists after a full client build.
This would be a problem in dev mode. So in dev mode the symbol is mapped to the expected URL using the symbolMapper function below. For Vite the given path is fixed for a given symbol.
symbolMapper: ReturnType<typeof createSymbolMapper>;
This API is provided as an alpha preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
For a given symbol (QRL such as onKeydown$) the server needs to know which bundle the symbol is in.
Normally this is provided by Qwik's q-manifest . But q-manifest only exists after a full client build.
This would be a problem in dev mode. So in dev mode the symbol is mapped to the expected URL using the symbolMapper function below. For Vite the given path is fixed for a given symbol.
symbolMapper: ReturnType<typeof createSymbolMapper>;
export type SymbolMapperFn = (
symbolName: string,
mapper: SymbolMapper | undefined,
parent?: string,
) => readonly [symbol: string, chunk: string] | undefined;
References: SymbolMapper
<h2 id="systemenvironment">SystemEnvironment</h2>export type SystemEnvironment =
| "node"
| "deno"
| "bun"
| "webworker"
| "browsermain"
| "unknown";
Transforms the directory from the file system.
transformFs(opts: TransformFsOptions): Promise<TransformOutput>;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>opts
</td><td> </td><td> </td></tr> </tbody></table>Returns:
Promise<TransformOutput>
<h2 id="transformfsoptions">TransformFsOptions</h2>export interface TransformFsOptions extends TransformOptions
Extends: TransformOptions
<table><thead><tr><th>Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string[]
</td><td> </td></tr> </tbody></table> <h2 id="optimizer-transformfssync">transformFsSync</h2>Transforms the directory from the file system.
transformFsSync(opts: TransformFsOptions): TransformOutput;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>opts
</td><td> </td><td> </td></tr> </tbody></table>Returns:
<h2 id="transformmodule">TransformModule</h2>export interface TransformModule
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>boolean
</td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>string | null
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>SegmentAnalysis | null
</td><td> </td></tr> </tbody></table> <h2 id="transformmoduleinput">TransformModuleInput</h2>export interface TransformModuleInput
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> </tbody></table> <h2 id="optimizer-transformmodules">transformModules</h2>Transforms the input code string, does not access the file system.
transformModules(opts: TransformModulesOptions): Promise<TransformOutput>;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>opts
</td><td> </td><td> </td></tr> </tbody></table>Returns:
Promise<TransformOutput>
<h2 id="transformmodulesoptions">TransformModulesOptions</h2>export interface TransformModulesOptions extends TransformOptions
Extends: TransformOptions
<table><thead><tr><th>Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td> </td></tr> </tbody></table> <h2 id="optimizer-transformmodulessync">transformModulesSync</h2>Transforms the input code string, does not access the file system.
transformModulesSync(opts: TransformModulesOptions): TransformOutput;
Parameter
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td>opts
</td><td> </td><td> </td></tr> </tbody></table>Returns:
<h2 id="transformoptions">TransformOptions</h2>export interface TransformOptions
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td> </td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>EmitMode
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string
</td><td> </td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>string[]
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> <tr><td> </td><td> </td><td>boolean
</td><td>(Optional)
</td></tr> </tbody></table> <h2 id="transformoutput">TransformOutput</h2>export interface TransformOutput
Property
</th><th>Modifiers
</th><th>Type
</th><th>Description
</th></tr></thead> <tbody><tr><td> </td><td> </td><td> </td><td> </td></tr> <tr><td> </td><td> </td><td>boolean
</td><td> </td></tr> <tr><td> </td><td> </td><td>boolean
</td><td> </td></tr> <tr><td> </td><td> </td><td> </td><td> </td></tr> </tbody></table> <h2 id="transpileoption">TranspileOption</h2>export type TranspileOption = boolean | undefined | null;
versions: {
qwik: string;
}