$ cnpm install @vuedx/transforms
A custom compiler to convert Vue template to a (functional) TSX representation for type checking.
npm add @vuedx/compiler-tsx
Signature:
declare function compile(template: string, options: Options & CompilerOptions): CodegenResult;
| Parameter | Type | Description |
|---|---|---|
| template | string |
- |
| options | Options & CompilerOptions |
- |
Signature:
declare function parse(template: string, options: ParserOptions): RootNode;
| Parameter | Type | Description |
|---|---|---|
| template | string |
- |
| options | ParserOptions |
- |
interface CodegenResult extends CodegenResult$1 {
errors: CompilerError[];
expressions: Array<[number, number]>;
mappings: Array<[number, number, number, number, number]>;
}
interface ComponentImport {
name?: string;
named?: boolean;
path: string;
}
interface Options {
components?: Record<string, ComponentImport>;
filename: string;
}
This package is part of VueDX project, maintained by Rahul Kadyan. You can ???? sponsor him for continued development of this package and other VueDX tools.
Copyright 2013 - present © cnpmjs.org | Home |