UNPKG

vite-require

Version:
33 lines (32 loc) 1.25 kB
import { type AcornNode } from './types'; export declare const multilineCommentsRE: RegExp; export declare const singlelineCommentsRE: RegExp; export declare const queryRE: RegExp; export declare const hashRE: RegExp; export declare const normallyIdRE: RegExp; export declare const extractIdRE: RegExp; export declare const JS_EXTENSIONS: string[]; export declare const KNOWN_SFC_EXTENSIONS: string[]; export declare const KNOWN_ASSET_TYPES: string[]; export declare const KNOWN_CSS_TYPES: string[]; export declare const builtins: string[]; export declare function cleanUrl(url: string): string; export declare function isCommonjs(code: string): boolean; export declare function simpleWalk(ast: AcornNode, visitors: { [type: string]: (node: AcornNode, ancestors: AcornNode[]) => void; }, ancestors?: AcornNode[]): void; export declare namespace simpleWalk { var async: () => void; } export declare class MagicString { str: string; private overwrites; private starts; private ends; constructor(str: string); append(content: string): this; prepend(content: string): this; overwrite(start: number, end: number, content: string): this; toString(): string; } export declare function parseId(id: string): string[];