+43
-33
@@ -82,2 +82,22 @@ export type Platform = 'browser' | 'node' | 'neutral' | ||
| logOverride?: Record<string, LogLevel> | ||
| /** Documentation: https://esbuild.github.io/api/#tsconfig-raw */ | ||
| tsconfigRaw?: string | { | ||
| compilerOptions?: { | ||
| alwaysStrict?: boolean | ||
| baseUrl?: boolean | ||
| experimentalDecorators?: boolean | ||
| importsNotUsedAsValues?: 'remove' | 'preserve' | 'error' | ||
| jsx?: 'preserve' | 'react-native' | 'react' | 'react-jsx' | 'react-jsxdev' | ||
| jsxFactory?: string | ||
| jsxFragmentFactory?: string | ||
| jsxImportSource?: string | ||
| paths?: Record<string, string[]> | ||
| preserveValueImports?: boolean | ||
| strict?: boolean | ||
| target?: string | ||
| useDefineForClassFields?: boolean | ||
| verbatimModuleSyntax?: boolean | ||
| } | ||
| } | ||
| } | ||
@@ -195,11 +215,11 @@ | ||
| export interface BuildResult<SpecificOptions extends BuildOptions = BuildOptions> { | ||
| export interface BuildResult<ProvidedOptions extends BuildOptions = BuildOptions> { | ||
| errors: Message[] | ||
| warnings: Message[] | ||
| /** Only when "write: false" */ | ||
| outputFiles: OutputFile[] | (SpecificOptions['write'] extends false ? never : undefined) | ||
| outputFiles: OutputFile[] | (ProvidedOptions['write'] extends false ? never : undefined) | ||
| /** Only when "metafile: true" */ | ||
| metafile: Metafile | (SpecificOptions['metafile'] extends true ? never : undefined) | ||
| metafile: Metafile | (ProvidedOptions['metafile'] extends true ? never : undefined) | ||
| /** Only when "mangleCache" is present */ | ||
| mangleCache: Record<string, string | false> | (SpecificOptions['mangleCache'] extends Object ? never : undefined) | ||
| mangleCache: Record<string, string | false> | (ProvidedOptions['mangleCache'] extends Object ? never : undefined) | ||
| } | ||
@@ -238,23 +258,13 @@ | ||
| export interface TransformOptions extends CommonOptions { | ||
| tsconfigRaw?: string | { | ||
| compilerOptions?: { | ||
| alwaysStrict?: boolean, | ||
| importsNotUsedAsValues?: 'remove' | 'preserve' | 'error', | ||
| jsx?: 'react' | 'react-jsx' | 'react-jsxdev' | 'preserve', | ||
| jsxFactory?: string, | ||
| jsxFragmentFactory?: string, | ||
| jsxImportSource?: string, | ||
| preserveValueImports?: boolean, | ||
| target?: string, | ||
| useDefineForClassFields?: boolean, | ||
| }, | ||
| } | ||
| /** Documentation: https://esbuild.github.io/api/#sourcefile */ | ||
| sourcefile?: string | ||
| /** Documentation: https://esbuild.github.io/api/#loader */ | ||
| loader?: Loader | ||
| /** Documentation: https://esbuild.github.io/api/#banner */ | ||
| banner?: string | ||
| /** Documentation: https://esbuild.github.io/api/#footer */ | ||
| footer?: string | ||
| } | ||
| export interface TransformResult<SpecificOptions extends TransformOptions = TransformOptions> { | ||
| export interface TransformResult<ProvidedOptions extends TransformOptions = TransformOptions> { | ||
| code: string | ||
@@ -264,5 +274,5 @@ map: string | ||
| /** Only when "mangleCache" is present */ | ||
| mangleCache: Record<string, string | false> | (SpecificOptions['mangleCache'] extends Object ? never : undefined) | ||
| mangleCache: Record<string, string | false> | (ProvidedOptions['mangleCache'] extends Object ? never : undefined) | ||
| /** Only when "legalComments" is "external" */ | ||
| legalComments: string | (SpecificOptions['legalComments'] extends 'external' ? never : undefined) | ||
| legalComments: string | (ProvidedOptions['legalComments'] extends 'external' ? never : undefined) | ||
| } | ||
@@ -494,5 +504,5 @@ | ||
| export interface BuildContext<SpecificOptions extends BuildOptions = BuildOptions> { | ||
| export interface BuildContext<ProvidedOptions extends BuildOptions = BuildOptions> { | ||
| /** Documentation: https://esbuild.github.io/api/#rebuild */ | ||
| rebuild(): Promise<BuildResult<SpecificOptions>> | ||
| rebuild(): Promise<BuildResult<ProvidedOptions>> | ||
@@ -509,2 +519,7 @@ /** Documentation: https://esbuild.github.io/api/#watch */ | ||
| // This is a TypeScript type-level function which replaces any keys in "In" | ||
| // that aren't in "Out" with "never". We use this to reject properties with | ||
| // typos in object literals. See: https://stackoverflow.com/questions/49580725 | ||
| type SameShape<Out, In extends Out> = In & { [Key in Exclude<keyof In, keyof Out>]: never } | ||
| /** | ||
@@ -520,4 +535,3 @@ * This function invokes the "esbuild" command-line tool for you. It returns a | ||
| */ | ||
| export declare function build<SpecificOptions extends BuildOptions>(options: SpecificOptions): Promise<BuildResult<SpecificOptions>> | ||
| export declare function build(options: BuildOptions): Promise<BuildResult> | ||
| export declare function build<T extends BuildOptions>(options: SameShape<BuildOptions, T>): Promise<BuildResult<T>> | ||
@@ -533,4 +547,3 @@ /** | ||
| */ | ||
| export declare function context<T extends BuildOptions>(options: T): Promise<BuildContext<T>> | ||
| export declare function context(options: BuildOptions): Promise<BuildContext> | ||
| export declare function context<T extends BuildOptions>(options: SameShape<BuildOptions, T>): Promise<BuildContext<T>> | ||
@@ -548,4 +561,3 @@ /** | ||
| */ | ||
| export declare function transform<SpecificOptions extends TransformOptions>(input: string | Uint8Array, options?: SpecificOptions): Promise<TransformResult<SpecificOptions>> | ||
| export declare function transform(input: string | Uint8Array, options?: TransformOptions): Promise<TransformResult> | ||
| export declare function transform<T extends TransformOptions>(input: string | Uint8Array, options?: SameShape<TransformOptions, T>): Promise<TransformResult<T>> | ||
@@ -582,4 +594,3 @@ /** | ||
| */ | ||
| export declare function buildSync<SpecificOptions extends BuildOptions>(options: SpecificOptions): BuildResult<SpecificOptions> | ||
| export declare function buildSync(options: BuildOptions): BuildResult | ||
| export declare function buildSync<T extends BuildOptions>(options: SameShape<BuildOptions, T>): BuildResult<T> | ||
@@ -594,4 +605,3 @@ /** | ||
| */ | ||
| export declare function transformSync<SpecificOptions extends TransformOptions>(input: string, options?: SpecificOptions): TransformResult<SpecificOptions> | ||
| export declare function transformSync(input: string | Uint8Array, options?: TransformOptions): TransformResult | ||
| export declare function transformSync<T extends TransformOptions>(input: string | Uint8Array, options?: SameShape<TransformOptions, T>): TransformResult<T> | ||
@@ -598,0 +608,0 @@ /** |
+23
-23
| { | ||
| "name": "esbuild", | ||
| "version": "0.17.19", | ||
| "version": "0.18.0", | ||
| "description": "An extremely fast JavaScript and CSS bundler and minifier.", | ||
@@ -18,26 +18,26 @@ "repository": "https://github.com/evanw/esbuild", | ||
| "optionalDependencies": { | ||
| "@esbuild/android-arm": "0.17.19", | ||
| "@esbuild/android-arm64": "0.17.19", | ||
| "@esbuild/android-x64": "0.17.19", | ||
| "@esbuild/darwin-arm64": "0.17.19", | ||
| "@esbuild/darwin-x64": "0.17.19", | ||
| "@esbuild/freebsd-arm64": "0.17.19", | ||
| "@esbuild/freebsd-x64": "0.17.19", | ||
| "@esbuild/linux-arm": "0.17.19", | ||
| "@esbuild/linux-arm64": "0.17.19", | ||
| "@esbuild/linux-ia32": "0.17.19", | ||
| "@esbuild/linux-loong64": "0.17.19", | ||
| "@esbuild/linux-mips64el": "0.17.19", | ||
| "@esbuild/linux-ppc64": "0.17.19", | ||
| "@esbuild/linux-riscv64": "0.17.19", | ||
| "@esbuild/linux-s390x": "0.17.19", | ||
| "@esbuild/linux-x64": "0.17.19", | ||
| "@esbuild/netbsd-x64": "0.17.19", | ||
| "@esbuild/openbsd-x64": "0.17.19", | ||
| "@esbuild/sunos-x64": "0.17.19", | ||
| "@esbuild/win32-arm64": "0.17.19", | ||
| "@esbuild/win32-ia32": "0.17.19", | ||
| "@esbuild/win32-x64": "0.17.19" | ||
| "@esbuild/android-arm": "0.18.0", | ||
| "@esbuild/android-arm64": "0.18.0", | ||
| "@esbuild/android-x64": "0.18.0", | ||
| "@esbuild/darwin-arm64": "0.18.0", | ||
| "@esbuild/darwin-x64": "0.18.0", | ||
| "@esbuild/freebsd-arm64": "0.18.0", | ||
| "@esbuild/freebsd-x64": "0.18.0", | ||
| "@esbuild/linux-arm": "0.18.0", | ||
| "@esbuild/linux-arm64": "0.18.0", | ||
| "@esbuild/linux-ia32": "0.18.0", | ||
| "@esbuild/linux-loong64": "0.18.0", | ||
| "@esbuild/linux-mips64el": "0.18.0", | ||
| "@esbuild/linux-ppc64": "0.18.0", | ||
| "@esbuild/linux-riscv64": "0.18.0", | ||
| "@esbuild/linux-s390x": "0.18.0", | ||
| "@esbuild/linux-x64": "0.18.0", | ||
| "@esbuild/netbsd-x64": "0.18.0", | ||
| "@esbuild/openbsd-x64": "0.18.0", | ||
| "@esbuild/sunos-x64": "0.18.0", | ||
| "@esbuild/win32-arm64": "0.18.0", | ||
| "@esbuild/win32-ia32": "0.18.0", | ||
| "@esbuild/win32-x64": "0.18.0" | ||
| }, | ||
| "license": "MIT" | ||
| } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 4 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 4 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
Found 2 instances in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
130436
0.24%3226
0.28%19
5.56%