diff --git a/CHANGELOG.md b/CHANGELOG.md index 93516a2d0f4..80657f59ca5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## Unreleased +## 0.9.1 * Fix bundling when parent directory is inaccessible ([#938](https://github.com/evanw/esbuild/issues/938)) @@ -46,7 +46,9 @@ Except that node doesn't actually ever look at the properties of that object to determine the export names. Instead it parses the CommonJS file and scans the AST for certain syntax patterns. A full list of supported patterns can be found in the [documentation for the `cjs-module-lexer` package](https://github.com/guybedford/cjs-module-lexer#grammar). This library doesn't currently support the syntax patterns used by esbuild. - While esbuild could adapt its syntax to these patterns, the patterns are less compact than the ones used by esbuild and doing this would lead to code bloat. Supporting two separate ways of generating export getters would also complicate esbuild's internal implementation, which is undesirable. Another alternative could be to update the implementation of `cjs-module-lexer` to support the specific patterns used by esbuild. This is also undesirable because this pattern detection would break when minification is enabled, this would tightly couple esbuild's output format with node and prevent esbuild from changing it, and it wouldn't work for existing and previous versions of node that still have the old version of this library. + While esbuild could adapt its syntax to these patterns, the patterns are less compact than the ones used by esbuild and doing this would lead to code bloat. Supporting two separate ways of generating export getters would also complicate esbuild's internal implementation, which is undesirable. + + Another alternative could be to update the implementation of `cjs-module-lexer` to support the specific patterns used by esbuild. This is also undesirable because this pattern detection would break when minification is enabled, this would tightly couple esbuild's output format with node and prevent esbuild from changing it, and it wouldn't work for existing and previous versions of node that still have the old version of this library. Instead, esbuild will now add additional code to "annotate" ESM files that have been converted to CommonJS when esbuild's platform has been set to `node`. The annotation is dead code but is still detected by the `cjs-module-lexer` library. If the original ESM file has the exports `foo` and `bar`, the additional annotation code will look like this: diff --git a/cmd/esbuild/version.go b/cmd/esbuild/version.go index 8f2af6c8370..f70ace97f77 100644 --- a/cmd/esbuild/version.go +++ b/cmd/esbuild/version.go @@ -1,3 +1,3 @@ package main -const esbuildVersion = "0.9.0" +const esbuildVersion = "0.9.1" diff --git a/npm/esbuild-darwin-64/package.json b/npm/esbuild-darwin-64/package.json index a7d61af456e..da74411443f 100644 --- a/npm/esbuild-darwin-64/package.json +++ b/npm/esbuild-darwin-64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-darwin-64", - "version": "0.9.0", + "version": "0.9.1", "description": "The macOS 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-darwin-arm64/package.json b/npm/esbuild-darwin-arm64/package.json index d607c5d085d..20494ebd1b5 100644 --- a/npm/esbuild-darwin-arm64/package.json +++ b/npm/esbuild-darwin-arm64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-darwin-arm64", - "version": "0.9.0", + "version": "0.9.1", "description": "The macOS ARM 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-freebsd-64/package.json b/npm/esbuild-freebsd-64/package.json index fbbea91cc68..b0dc5123e90 100644 --- a/npm/esbuild-freebsd-64/package.json +++ b/npm/esbuild-freebsd-64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-freebsd-64", - "version": "0.9.0", + "version": "0.9.1", "description": "The FreeBSD 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-freebsd-arm64/package.json b/npm/esbuild-freebsd-arm64/package.json index 10bf0f8e8eb..b7b9e8b1d68 100644 --- a/npm/esbuild-freebsd-arm64/package.json +++ b/npm/esbuild-freebsd-arm64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-freebsd-arm64", - "version": "0.9.0", + "version": "0.9.1", "description": "The FreeBSD ARM 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-32/package.json b/npm/esbuild-linux-32/package.json index a8d4ba6df58..cf5b0f36f4a 100644 --- a/npm/esbuild-linux-32/package.json +++ b/npm/esbuild-linux-32/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-32", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux 32-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-64/package.json b/npm/esbuild-linux-64/package.json index b93089b9eb1..ead6cc7098b 100644 --- a/npm/esbuild-linux-64/package.json +++ b/npm/esbuild-linux-64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-64", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-arm/package.json b/npm/esbuild-linux-arm/package.json index 28da7245b10..fddce2d62ef 100644 --- a/npm/esbuild-linux-arm/package.json +++ b/npm/esbuild-linux-arm/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-arm", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux ARM binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-arm64/package.json b/npm/esbuild-linux-arm64/package.json index 7a5b55c8fdf..8bd766681d0 100644 --- a/npm/esbuild-linux-arm64/package.json +++ b/npm/esbuild-linux-arm64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-arm64", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux ARM 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-mips64le/package.json b/npm/esbuild-linux-mips64le/package.json index f5ef44266d0..cd5533e2adb 100644 --- a/npm/esbuild-linux-mips64le/package.json +++ b/npm/esbuild-linux-mips64le/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-mips64le", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux MIPS 64-bit Little Endian binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-linux-ppc64le/package.json b/npm/esbuild-linux-ppc64le/package.json index b75cf54964c..2f025cb4e33 100644 --- a/npm/esbuild-linux-ppc64le/package.json +++ b/npm/esbuild-linux-ppc64le/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-linux-ppc64le", - "version": "0.9.0", + "version": "0.9.1", "description": "The Linux PowerPC 64-bit Little Endian binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-wasm/package.json b/npm/esbuild-wasm/package.json index 71d82ebbea7..3eaf2ae1a63 100644 --- a/npm/esbuild-wasm/package.json +++ b/npm/esbuild-wasm/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-wasm", - "version": "0.9.0", + "version": "0.9.1", "description": "The cross-platform WebAssembly binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-windows-32/package.json b/npm/esbuild-windows-32/package.json index 1090b0b893a..8b3c9ff2cfc 100644 --- a/npm/esbuild-windows-32/package.json +++ b/npm/esbuild-windows-32/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-windows-32", - "version": "0.9.0", + "version": "0.9.1", "description": "The Windows 32-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild-windows-64/package.json b/npm/esbuild-windows-64/package.json index 0d5b06ce6d0..b562923aa75 100644 --- a/npm/esbuild-windows-64/package.json +++ b/npm/esbuild-windows-64/package.json @@ -1,6 +1,6 @@ { "name": "esbuild-windows-64", - "version": "0.9.0", + "version": "0.9.1", "description": "The Windows 64-bit binary for esbuild, a JavaScript bundler.", "repository": "https://github.com/evanw/esbuild", "license": "MIT", diff --git a/npm/esbuild/package.json b/npm/esbuild/package.json index 0af1ad5fe86..bf5f0784285 100644 --- a/npm/esbuild/package.json +++ b/npm/esbuild/package.json @@ -1,6 +1,6 @@ { "name": "esbuild", - "version": "0.9.0", + "version": "0.9.1", "description": "An extremely fast JavaScript bundler and minifier.", "repository": "https://github.com/evanw/esbuild", "scripts": { diff --git a/version.txt b/version.txt index ac39a106c48..f374f6662e9 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -0.9.0 +0.9.1