esbuild-wasm
Advanced tools
Comparing version 0.3.1 to 0.3.2
@@ -7,3 +7,4 @@ export declare type Target = 'esnext' | 'es6' | 'es2015' | 'es2016' | 'es2017' | 'es2018' | 'es2019' | 'es2020'; | ||
interface CommonOptions { | ||
sourcemap?: boolean; | ||
sourcemap?: boolean | 'inline' | 'external'; | ||
sourcefile?: string; | ||
errorLimit?: number; | ||
@@ -10,0 +11,0 @@ target?: Target; |
@@ -37,6 +37,7 @@ const child_process = require('child_process'); | ||
function pushCommonFlags(flags, options) { | ||
function pushCommonFlags(flags, options, defaults) { | ||
flags.push(`--error-limit=${options.errorLimit || 0}`); | ||
if (options.sourcemap) flags.push('--sourcemap'); | ||
if (options.sourcemap) flags.push(`--sourcemap=${options.sourcemap === true ? defaults.sourcemap : options.sourcemap}`); | ||
if (options.sourcefile) flags.push(`--sourcefile=${options.sourcefile}`); | ||
if (options.target) flags.push(`--target=${options.target}`); | ||
@@ -66,3 +67,3 @@ | ||
const flags = []; | ||
pushCommonFlags(flags, options); | ||
pushCommonFlags(flags, options, { sourcemap: true }); | ||
@@ -265,3 +266,3 @@ if (options.name) flags.push(`--name=${options.name}`); | ||
const flags = ['build', `/${name}`, file, '--', name, '--outfile=/output.js']; | ||
pushCommonFlags(flags, options); | ||
pushCommonFlags(flags, options, { sourcemap: 'external' }); | ||
if (options.loader) flags.push(`--loader:.${loader}=${options.loader}`); | ||
@@ -268,0 +269,0 @@ const response = await sendRequest(flags); |
{ | ||
"name": "esbuild-wasm", | ||
"version": "0.3.1", | ||
"version": "0.3.2", | ||
"description": "The cross-platform WebAssembly binary for esbuild, a JavaScript bundler.", | ||
@@ -5,0 +5,0 @@ "repository": "https://github.com/evanw/esbuild", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
4537116
1154
3