Bump esbuild from 0.16.14 to 0.16.16 #340

Closed
dependabot[bot] wants to merge 1 commit from dependabot/npm_and_yarn/esbuild-0.16.16 into master
dependabot[bot] commented 2023-01-09 11:08:09 +01:00 (Migrated from github.com)

Bumps esbuild from 0.16.14 to 0.16.16.

Release notes

Sourced from esbuild's releases.

v0.16.16

  • Fix a regression caused by comment preservation (#2805)

    The new comment preservation behavior that was added in 0.16.14 introduced a regression where comments in certain locations could cause esbuild to omit certain necessary parentheses in the output. The outermost parentheses were incorrectly removed for the following syntax forms, which then introduced syntax errors:

    (/* comment */ { x: 0 }).x;
    (/* comment */ function () { })();
    (/* comment */ class { }).prototype;
    

    This regression has been fixed.

v0.16.15

  • Add format to input files in the JSON metafile data

    When --metafile is enabled, input files may now have an additional format field that indicates the export format used by this file. When present, the value will either be cjs for CommonJS-style exports or esm for ESM-style exports. This can be useful in bundle analysis.

    For example, esbuild's new Bundle Size Analyzer now uses this information to visualize whether ESM or CommonJS was used for each directory and file of source code (click on the CJS/ESM bar at the top).

    This information is helpful when trying to reduce the size of your bundle. Using the ESM variant of a dependency instead of the CommonJS variant always results in a faster and smaller bundle because it omits CommonJS wrappers, and also may result in better tree-shaking as it allows esbuild to perform tree-shaking at the statement level instead of the module level.

  • Fix a bundling edge case with dynamic import (#2793)

    This release fixes a bug where esbuild's bundler could produce incorrect output. The problematic edge case involves the entry point importing itself using a dynamic import() expression in an imported file, like this:

    // src/a.js
    export const A = 42;
    

    // src/b.js export const B = async () => (await import(".")).A

    // src/index.js export * from "./a" export * from "./b"

  • Remove new type syntax from type declarations in the esbuild package (#2798)

    Previously you needed to use TypeScript 4.3 or newer when using the esbuild package from TypeScript code due to the use of a getter in an interface in node_modules/esbuild/lib/main.d.ts. This release removes this newer syntax to allow people with versions of TypeScript as far back as TypeScript 3.5 to use this latest version of the esbuild package. Here is change that was made to esbuild's type declarations:

     export interface OutputFile {
       /** "text" as bytes */
       contents: Uint8Array;
       /** "contents" as text (changes automatically with "contents") */
    -  get text(): string;
    +  readonly text: string;
     }
    

... (truncated)

Changelog

Sourced from esbuild's changelog.

0.16.16

  • Fix a regression caused by comment preservation (#2805)

    The new comment preservation behavior that was added in 0.16.14 introduced a regression where comments in certain locations could cause esbuild to omit certain necessary parentheses in the output. The outermost parentheses were incorrectly removed for the following syntax forms, which then introduced syntax errors:

    (/* comment */ { x: 0 }).x;
    (/* comment */ function () { })();
    (/* comment */ class { }).prototype;
    

    This regression has been fixed.

0.16.15

  • Add format to input files in the JSON metafile data

    When --metafile is enabled, input files may now have an additional format field that indicates the export format used by this file. When present, the value will either be cjs for CommonJS-style exports or esm for ESM-style exports. This can be useful in bundle analysis.

    For example, esbuild's new Bundle Size Analyzer now uses this information to visualize whether ESM or CommonJS was used for each directory and file of source code (click on the CJS/ESM bar at the top).

    This information is helpful when trying to reduce the size of your bundle. Using the ESM variant of a dependency instead of the CommonJS variant always results in a faster and smaller bundle because it omits CommonJS wrappers, and also may result in better tree-shaking as it allows esbuild to perform tree-shaking at the statement level instead of the module level.

  • Fix a bundling edge case with dynamic import (#2793)

    This release fixes a bug where esbuild's bundler could produce incorrect output. The problematic edge case involves the entry point importing itself using a dynamic import() expression in an imported file, like this:

    // src/a.js
    export const A = 42;
    

    // src/b.js export const B = async () => (await import(".")).A

    // src/index.js export * from "./a" export * from "./b"

  • Remove new type syntax from type declarations in the esbuild package (#2798)

    Previously you needed to use TypeScript 4.3 or newer when using the esbuild package from TypeScript code due to the use of a getter in an interface in node_modules/esbuild/lib/main.d.ts. This release removes this newer syntax to allow people with versions of TypeScript as far back as TypeScript 3.5 to use this latest version of the esbuild package. Here is change that was made to esbuild's type declarations:

     export interface OutputFile {
       /** "text" as bytes */
       contents: Uint8Array;
       /** "contents" as text (changes automatically with "contents") */
    -  get text(): string;
    

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.16.14 to 0.16.16. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/evanw/esbuild/releases">esbuild's releases</a>.</em></p> <blockquote> <h2>v0.16.16</h2> <ul> <li> <p>Fix a regression caused by comment preservation (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2805">#2805</a>)</p> <p>The new comment preservation behavior that was added in 0.16.14 introduced a regression where comments in certain locations could cause esbuild to omit certain necessary parentheses in the output. The outermost parentheses were incorrectly removed for the following syntax forms, which then introduced syntax errors:</p> <pre lang="js"><code>(/* comment */ { x: 0 }).x; (/* comment */ function () { })(); (/* comment */ class { }).prototype; </code></pre> <p>This regression has been fixed.</p> </li> </ul> <h2>v0.16.15</h2> <ul> <li> <p>Add <code>format</code> to input files in the JSON metafile data</p> <p>When <code>--metafile</code> is enabled, input files may now have an additional <code>format</code> field that indicates the export format used by this file. When present, the value will either be <code>cjs</code> for CommonJS-style exports or <code>esm</code> for ESM-style exports. This can be useful in bundle analysis.</p> <p>For example, esbuild's new <a href="https://esbuild.github.io/analyze/">Bundle Size Analyzer</a> now uses this information to visualize whether ESM or CommonJS was used for each directory and file of source code (click on the CJS/ESM bar at the top).</p> <p>This information is helpful when trying to reduce the size of your bundle. Using the ESM variant of a dependency instead of the CommonJS variant always results in a faster and smaller bundle because it omits CommonJS wrappers, and also may result in better tree-shaking as it allows esbuild to perform tree-shaking at the statement level instead of the module level.</p> </li> <li> <p>Fix a bundling edge case with dynamic import (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2793">#2793</a>)</p> <p>This release fixes a bug where esbuild's bundler could produce incorrect output. The problematic edge case involves the entry point importing itself using a dynamic <code>import()</code> expression in an imported file, like this:</p> <pre lang="js"><code>// src/a.js export const A = 42; <p>// src/b.js export const B = async () =&gt; (await import(&quot;.&quot;)).A</p> <p>// src/index.js export * from &quot;./a&quot; export * from &quot;./b&quot; </code></pre></p> </li> <li> <p>Remove new type syntax from type declarations in the <code>esbuild</code> package (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2798">#2798</a>)</p> <p>Previously you needed to use TypeScript 4.3 or newer when using the <code>esbuild</code> package from TypeScript code due to the use of a getter in an interface in <code>node_modules/esbuild/lib/main.d.ts</code>. This release removes this newer syntax to allow people with versions of TypeScript as far back as TypeScript 3.5 to use this latest version of the <code>esbuild</code> package. Here is change that was made to esbuild's type declarations:</p> <pre lang="diff"><code> export interface OutputFile { /** &quot;text&quot; as bytes */ contents: Uint8Array; /** &quot;contents&quot; as text (changes automatically with &quot;contents&quot;) */ - get text(): string; + readonly text: string; } </code></pre> </li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/evanw/esbuild/blob/main/CHANGELOG.md">esbuild's changelog</a>.</em></p> <blockquote> <h2>0.16.16</h2> <ul> <li> <p>Fix a regression caused by comment preservation (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2805">#2805</a>)</p> <p>The new comment preservation behavior that was added in 0.16.14 introduced a regression where comments in certain locations could cause esbuild to omit certain necessary parentheses in the output. The outermost parentheses were incorrectly removed for the following syntax forms, which then introduced syntax errors:</p> <pre lang="js"><code>(/* comment */ { x: 0 }).x; (/* comment */ function () { })(); (/* comment */ class { }).prototype; </code></pre> <p>This regression has been fixed.</p> </li> </ul> <h2>0.16.15</h2> <ul> <li> <p>Add <code>format</code> to input files in the JSON metafile data</p> <p>When <code>--metafile</code> is enabled, input files may now have an additional <code>format</code> field that indicates the export format used by this file. When present, the value will either be <code>cjs</code> for CommonJS-style exports or <code>esm</code> for ESM-style exports. This can be useful in bundle analysis.</p> <p>For example, esbuild's new <a href="https://esbuild.github.io/analyze/">Bundle Size Analyzer</a> now uses this information to visualize whether ESM or CommonJS was used for each directory and file of source code (click on the CJS/ESM bar at the top).</p> <p>This information is helpful when trying to reduce the size of your bundle. Using the ESM variant of a dependency instead of the CommonJS variant always results in a faster and smaller bundle because it omits CommonJS wrappers, and also may result in better tree-shaking as it allows esbuild to perform tree-shaking at the statement level instead of the module level.</p> </li> <li> <p>Fix a bundling edge case with dynamic import (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2793">#2793</a>)</p> <p>This release fixes a bug where esbuild's bundler could produce incorrect output. The problematic edge case involves the entry point importing itself using a dynamic <code>import()</code> expression in an imported file, like this:</p> <pre lang="js"><code>// src/a.js export const A = 42; <p>// src/b.js export const B = async () =&gt; (await import(&quot;.&quot;)).A</p> <p>// src/index.js export * from &quot;./a&quot; export * from &quot;./b&quot; </code></pre></p> </li> <li> <p>Remove new type syntax from type declarations in the <code>esbuild</code> package (<a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2798">#2798</a>)</p> <p>Previously you needed to use TypeScript 4.3 or newer when using the <code>esbuild</code> package from TypeScript code due to the use of a getter in an interface in <code>node_modules/esbuild/lib/main.d.ts</code>. This release removes this newer syntax to allow people with versions of TypeScript as far back as TypeScript 3.5 to use this latest version of the <code>esbuild</code> package. Here is change that was made to esbuild's type declarations:</p> <pre lang="diff"><code> export interface OutputFile { /** &quot;text&quot; as bytes */ contents: Uint8Array; /** &quot;contents&quot; as text (changes automatically with &quot;contents&quot;) */ - get text(): string; </code></pre> </li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/evanw/esbuild/commit/edede3c49ad6adddc6ea5b3c78c6ea7507e03020"><code>edede3c</code></a> publish 0.16.16 to npm</li> <li><a href="https://github.com/evanw/esbuild/commit/7d89263e101fae532065a10b611cb12cbc9a3ce2"><code>7d89263</code></a> fix <a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2805">#2805</a>: parentheses for commented expressions</li> <li><a href="https://github.com/evanw/esbuild/commit/9df9a6565b55530878c405bfa6c696182ce5e7a5"><code>9df9a65</code></a> only register plugin callbacks if needed</li> <li><a href="https://github.com/evanw/esbuild/commit/33a515951c626e56addc1dd4c6561a1514559fd0"><code>33a5159</code></a> publish 0.16.15 to npm</li> <li><a href="https://github.com/evanw/esbuild/commit/b3b06c780a673e6b74dce4bb697ead8f6fce2514"><code>b3b06c7</code></a> fix <a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2798">#2798</a>: make type declarations work in TS v3.5+</li> <li><a href="https://github.com/evanw/esbuild/commit/dad3e64539e48b457515d4b25ef4b674d55c06e5"><code>dad3e64</code></a> fix <a href="https://github-redirect.dependabot.com/evanw/esbuild/issues/2793">#2793</a>: bundling edge case with dynamic import</li> <li><a href="https://github.com/evanw/esbuild/commit/6398f81be771d89a2efcc08e578be99cb981de6b"><code>6398f81</code></a> add <code>&quot;format&quot;</code> to inputs in metafile</li> <li><a href="https://github.com/evanw/esbuild/commit/c572af4ef822e6a079440d212ac01a59e7f39dea"><code>c572af4</code></a> <code>JSON.parse</code> + <code>JSON.stringify</code>: no side effects</li> <li>See full diff in <a href="https://github.com/evanw/esbuild/compare/v0.16.14...v0.16.16">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=esbuild&package-manager=npm_and_yarn&previous-version=0.16.14&new-version=0.16.16)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details>
dependabot[bot] commented 2023-01-12 11:04:17 +01:00 (Migrated from github.com)

Superseded by #342.

Superseded by #342.
Commenting is not possible because the repository is archived.
No description provided.