mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-11-21 14:13:36 +08:00
chore:更换到主分支
This commit is contained in:
195
node_modules/esbuild/lib/main.d.ts
generated
vendored
195
node_modules/esbuild/lib/main.d.ts
generated
vendored
@@ -1,28 +1,33 @@
|
||||
export type Platform = 'browser' | 'node';
|
||||
export type Platform = 'browser' | 'node' | 'neutral';
|
||||
export type Format = 'iife' | 'cjs' | 'esm';
|
||||
export type Loader = 'js' | 'jsx' | 'ts' | 'tsx' | 'css' | 'json' | 'text' | 'base64' | 'file' | 'dataurl' | 'binary';
|
||||
export type Loader = 'js' | 'jsx' | 'ts' | 'tsx' | 'css' | 'json' | 'text' | 'base64' | 'file' | 'dataurl' | 'binary' | 'default';
|
||||
export type LogLevel = 'info' | 'warning' | 'error' | 'silent';
|
||||
export type Strict = 'nullish-coalescing' | 'optional-chaining' | 'class-fields';
|
||||
export type Charset = 'ascii' | 'utf8';
|
||||
export type TreeShaking = true | 'ignore-annotations';
|
||||
|
||||
interface CommonOptions {
|
||||
sourcemap?: boolean | 'inline' | 'external';
|
||||
sourcemap?: boolean | 'inline' | 'external' | 'both';
|
||||
sourcesContent?: boolean;
|
||||
|
||||
format?: Format;
|
||||
globalName?: string;
|
||||
target?: string | string[];
|
||||
strict?: boolean | Strict[];
|
||||
|
||||
minify?: boolean;
|
||||
minifyWhitespace?: boolean;
|
||||
minifyIdentifiers?: boolean;
|
||||
minifySyntax?: boolean;
|
||||
charset?: Charset;
|
||||
treeShaking?: TreeShaking;
|
||||
|
||||
jsxFactory?: string;
|
||||
jsxFragment?: string;
|
||||
define?: { [key: string]: string };
|
||||
pure?: string[];
|
||||
avoidTDZ?: boolean;
|
||||
keepNames?: boolean;
|
||||
banner?: string;
|
||||
footer?: string;
|
||||
|
||||
color?: boolean;
|
||||
logLevel?: LogLevel;
|
||||
@@ -32,11 +37,12 @@ interface CommonOptions {
|
||||
export interface BuildOptions extends CommonOptions {
|
||||
bundle?: boolean;
|
||||
splitting?: boolean;
|
||||
preserveSymlinks?: boolean;
|
||||
outfile?: string;
|
||||
metafile?: string;
|
||||
outdir?: string;
|
||||
outbase?: string;
|
||||
platform?: Platform;
|
||||
color?: boolean;
|
||||
external?: string[];
|
||||
loader?: { [ext: string]: Loader };
|
||||
resolveExtensions?: string[];
|
||||
@@ -45,10 +51,20 @@ export interface BuildOptions extends CommonOptions {
|
||||
tsconfig?: string;
|
||||
outExtension?: { [ext: string]: string };
|
||||
publicPath?: string;
|
||||
chunkNames?: string;
|
||||
assetNames?: string;
|
||||
inject?: string[];
|
||||
|
||||
incremental?: boolean;
|
||||
entryPoints?: string[];
|
||||
stdin?: StdinOptions;
|
||||
plugins?: Plugin[];
|
||||
absWorkingDir?: string;
|
||||
nodePaths?: string[]; // The "NODE_PATH" variable from Node.js
|
||||
watch?: boolean | WatchMode;
|
||||
}
|
||||
|
||||
export interface WatchMode {
|
||||
onRebuild?: (error: BuildFailure | null, result: BuildResult | null) => void;
|
||||
}
|
||||
|
||||
export interface StdinOptions {
|
||||
@@ -61,10 +77,21 @@ export interface StdinOptions {
|
||||
export interface Message {
|
||||
text: string;
|
||||
location: Location | null;
|
||||
notes: Note[];
|
||||
|
||||
// Optional user-specified data that is passed through unmodified. You can
|
||||
// use this to stash the original error, for example.
|
||||
detail: any;
|
||||
}
|
||||
|
||||
export interface Note {
|
||||
text: string;
|
||||
location: Location | null;
|
||||
}
|
||||
|
||||
export interface Location {
|
||||
file: string;
|
||||
namespace: string;
|
||||
line: number; // 1-based
|
||||
column: number; // 0-based, in bytes
|
||||
length: number; // in bytes
|
||||
@@ -73,12 +100,24 @@ export interface Location {
|
||||
|
||||
export interface OutputFile {
|
||||
path: string;
|
||||
contents: Uint8Array;
|
||||
contents: Uint8Array; // "text" as bytes
|
||||
text: string; // "contents" as text
|
||||
}
|
||||
|
||||
export interface BuildInvalidate {
|
||||
(): Promise<BuildIncremental>;
|
||||
dispose(): void;
|
||||
}
|
||||
|
||||
export interface BuildIncremental extends BuildResult {
|
||||
rebuild: BuildInvalidate;
|
||||
}
|
||||
|
||||
export interface BuildResult {
|
||||
warnings: Message[];
|
||||
outputFiles?: OutputFile[]; // Only when "write: false"
|
||||
rebuild?: BuildInvalidate; // Only when "incremental: true"
|
||||
stop?: () => void; // Only when "watch: true"
|
||||
}
|
||||
|
||||
export interface BuildFailure extends Error {
|
||||
@@ -86,6 +125,28 @@ export interface BuildFailure extends Error {
|
||||
warnings: Message[];
|
||||
}
|
||||
|
||||
export interface ServeOptions {
|
||||
port?: number;
|
||||
host?: string;
|
||||
servedir?: string;
|
||||
onRequest?: (args: ServeOnRequestArgs) => void;
|
||||
}
|
||||
|
||||
export interface ServeOnRequestArgs {
|
||||
remoteAddress: string;
|
||||
method: string;
|
||||
path: string;
|
||||
status: number;
|
||||
timeInMS: number; // The time to generate the response, not to send it
|
||||
}
|
||||
|
||||
export interface ServeResult {
|
||||
port: number;
|
||||
host: string;
|
||||
wait: Promise<void>;
|
||||
stop: () => void;
|
||||
}
|
||||
|
||||
export interface TransformOptions extends CommonOptions {
|
||||
tsconfigRaw?: string | {
|
||||
compilerOptions?: {
|
||||
@@ -101,8 +162,8 @@ export interface TransformOptions extends CommonOptions {
|
||||
}
|
||||
|
||||
export interface TransformResult {
|
||||
js: string;
|
||||
jsSourceMap: string;
|
||||
code: string;
|
||||
map: string;
|
||||
warnings: Message[];
|
||||
}
|
||||
|
||||
@@ -111,6 +172,103 @@ export interface TransformFailure extends Error {
|
||||
warnings: Message[];
|
||||
}
|
||||
|
||||
export interface Plugin {
|
||||
name: string;
|
||||
setup: (build: PluginBuild) => void;
|
||||
}
|
||||
|
||||
export interface PluginBuild {
|
||||
onResolve(options: OnResolveOptions, callback: (args: OnResolveArgs) =>
|
||||
(OnResolveResult | null | undefined | Promise<OnResolveResult | null | undefined>)): void;
|
||||
onLoad(options: OnLoadOptions, callback: (args: OnLoadArgs) =>
|
||||
(OnLoadResult | null | undefined | Promise<OnLoadResult | null | undefined>)): void;
|
||||
}
|
||||
|
||||
export interface OnResolveOptions {
|
||||
filter: RegExp;
|
||||
namespace?: string;
|
||||
}
|
||||
|
||||
export interface OnResolveArgs {
|
||||
path: string;
|
||||
importer: string;
|
||||
namespace: string;
|
||||
resolveDir: string;
|
||||
kind: ResolveKind;
|
||||
pluginData: any;
|
||||
}
|
||||
|
||||
export type ResolveKind =
|
||||
| 'entry-point'
|
||||
|
||||
// JS
|
||||
| 'import-statement'
|
||||
| 'require-call'
|
||||
| 'dynamic-import'
|
||||
| 'require-resolve'
|
||||
|
||||
// CSS
|
||||
| 'import-rule'
|
||||
| 'url-token'
|
||||
|
||||
export interface OnResolveResult {
|
||||
pluginName?: string;
|
||||
|
||||
errors?: PartialMessage[];
|
||||
warnings?: PartialMessage[];
|
||||
|
||||
path?: string;
|
||||
external?: boolean;
|
||||
namespace?: string;
|
||||
pluginData?: any;
|
||||
}
|
||||
|
||||
export interface OnLoadOptions {
|
||||
filter: RegExp;
|
||||
namespace?: string;
|
||||
}
|
||||
|
||||
export interface OnLoadArgs {
|
||||
path: string;
|
||||
namespace: string;
|
||||
pluginData: any;
|
||||
}
|
||||
|
||||
export interface OnLoadResult {
|
||||
pluginName?: string;
|
||||
|
||||
errors?: PartialMessage[];
|
||||
warnings?: PartialMessage[];
|
||||
|
||||
contents?: string | Uint8Array;
|
||||
resolveDir?: string;
|
||||
loader?: Loader;
|
||||
pluginData?: any;
|
||||
}
|
||||
|
||||
export interface PartialMessage {
|
||||
text?: string;
|
||||
location?: Partial<Location> | null;
|
||||
notes?: PartialNote[];
|
||||
detail?: any;
|
||||
}
|
||||
|
||||
export interface PartialNote {
|
||||
text?: string;
|
||||
location?: Partial<Location> | null;
|
||||
}
|
||||
|
||||
export type MetadataImportKind =
|
||||
// JS
|
||||
| 'import-statement'
|
||||
| 'require-call'
|
||||
| 'dynamic-import'
|
||||
| 'require-resolve'
|
||||
|
||||
// CSS
|
||||
| 'import-rule'
|
||||
| 'url-token'
|
||||
|
||||
// This is the type information for the "metafile" JSON format
|
||||
export interface Metadata {
|
||||
inputs: {
|
||||
@@ -118,6 +276,7 @@ export interface Metadata {
|
||||
bytes: number
|
||||
imports: {
|
||||
path: string
|
||||
kind: MetadataImportKind
|
||||
}[]
|
||||
}
|
||||
}
|
||||
@@ -131,13 +290,19 @@ export interface Metadata {
|
||||
}
|
||||
imports: {
|
||||
path: string
|
||||
kind: MetadataImportKind
|
||||
}[]
|
||||
exports: string[]
|
||||
entryPoint?: string
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export interface Service {
|
||||
build(options: BuildOptions & { write: false }): Promise<BuildResult & { outputFiles: OutputFile[] }>;
|
||||
build(options: BuildOptions & { incremental: true }): Promise<BuildIncremental>;
|
||||
build(options: BuildOptions): Promise<BuildResult>;
|
||||
serve(serveOptions: ServeOptions, buildOptions: BuildOptions): Promise<ServeResult>;
|
||||
transform(input: string, options?: TransformOptions): Promise<TransformResult>;
|
||||
|
||||
// This stops the service, which kills the long-lived child process. Any
|
||||
@@ -151,8 +316,17 @@ export interface Service {
|
||||
//
|
||||
// Works in node: yes
|
||||
// Works in browser: no
|
||||
export declare function build(options: BuildOptions & { write: false }): Promise<BuildResult & { outputFiles: OutputFile[] }>;
|
||||
export declare function build(options: BuildOptions & { incremental: true }): Promise<BuildIncremental>;
|
||||
export declare function build(options: BuildOptions): Promise<BuildResult>;
|
||||
|
||||
// This function is similar to "build" but it serves the resulting files over
|
||||
// HTTP on a localhost address with the specified port.
|
||||
//
|
||||
// Works in node: yes
|
||||
// Works in browser: no
|
||||
export declare function serve(serveOptions: ServeOptions, buildOptions: BuildOptions): Promise<ServeResult>;
|
||||
|
||||
// This function transforms a single JavaScript file. It can be used to minify
|
||||
// JavaScript, convert TypeScript/JSX to JavaScript, or convert newer JavaScript
|
||||
// to older JavaScript. It returns a promise that is either resolved with a
|
||||
@@ -166,6 +340,7 @@ export declare function transform(input: string, options?: TransformOptions): Pr
|
||||
//
|
||||
// Works in node: yes
|
||||
// Works in browser: no
|
||||
export declare function buildSync(options: BuildOptions & { write: false }): BuildResult & { outputFiles: OutputFile[] };
|
||||
export declare function buildSync(options: BuildOptions): BuildResult;
|
||||
|
||||
// A synchronous version of "transform".
|
||||
|
||||
1056
node_modules/esbuild/lib/main.js
generated
vendored
1056
node_modules/esbuild/lib/main.js
generated
vendored
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user