Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: bump esbuild from 0.14.5 to 0.14.6 #25

Merged
merged 1 commit into from
Dec 20, 2021

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Dec 20, 2021

Bumps esbuild from 0.14.5 to 0.14.6.

Release notes

Sourced from esbuild's releases.

v0.14.6

  • Fix a minifier bug with BigInt literals

    Previously expression simplification optimizations in the minifier incorrectly assumed that numeric operators always return numbers. This used to be true but has no longer been true since the introduction of BigInt literals in ES2020. Now numeric operators can return either a number or a BigInt depending on the arguments. This oversight could potentially have resulted in behavior changes. For example, this code printed false before being minified and true after being minified because esbuild shortened === to == under the false assumption that both operands were numbers:

    var x = 0;
    console.log((x ? 2 : -1n) === -1);

    The type checking logic has been rewritten to take into account BigInt literals in this release, so this incorrect simplification is no longer applied.

  • Enable removal of certain unused template literals (#1853)

    This release contains improvements to the minification of unused template literals containing primitive values:

    // Original code
    `${1}${2}${3}`;
    `${x ? 1 : 2}${y}`;
    // Old output (with --minify)
    ""+1+2+3,""+(x?1:2)+y;
    // New output (with --minify)
    x,${y};

    This can arise when the template literals are nested inside of another function call that was determined to be unnecessary such as an unused call to a function marked with the /* @__PURE__ */ pragma.

    This release also fixes a bug with this transformation where minifying the unused expression `foo ${bar}` into "" + bar changed the meaning of the expression. Template string interpolation always calls toString while string addition may call valueOf instead. This unused expression is now minified to `${bar}`, which is slightly longer but which avoids the behavior change.

  • Allow keyof/readonly/infer in TypeScript index signatures (#1859)

    This release fixes a bug that prevented these keywords from being used as names in index signatures. The following TypeScript code was previously rejected, but is now accepted:

    interface Foo {
      [keyof: string]: number
    }

    This fix was contributed by @​magic-akari.

  • Avoid warning about import.meta if it's replaced (#1868)

    It's possible to replace the import.meta expression using the --define: feature. Previously doing that still warned that the import.meta syntax was not supported when targeting ES5. With this release, there will no longer be a warning in this case.

Changelog

Sourced from esbuild's changelog.

0.14.6

  • Fix a minifier bug with BigInt literals

    Previously expression simplification optimizations in the minifier incorrectly assumed that numeric operators always return numbers. This used to be true but has no longer been true since the introduction of BigInt literals in ES2020. Now numeric operators can return either a number or a BigInt depending on the arguments. This oversight could potentially have resulted in behavior changes. For example, this code printed false before being minified and true after being minified because esbuild shortened === to == under the false assumption that both operands were numbers:

    var x = 0;
    console.log((x ? 2 : -1n) === -1);

    The type checking logic has been rewritten to take into account BigInt literals in this release, so this incorrect simplification is no longer applied.

  • Enable removal of certain unused template literals (#1853)

    This release contains improvements to the minification of unused template literals containing primitive values:

    // Original code
    `${1}${2}${3}`;
    `${x ? 1 : 2}${y}`;
    // Old output (with --minify)
    ""+1+2+3,""+(x?1:2)+y;
    // New output (with --minify)
    x,${y};

    This can arise when the template literals are nested inside of another function call that was determined to be unnecessary such as an unused call to a function marked with the /* @__PURE__ */ pragma.

    This release also fixes a bug with this transformation where minifying the unused expression `foo ${bar}` into "" + bar changed the meaning of the expression. Template string interpolation always calls toString while string addition may call valueOf instead. This unused expression is now minified to `${bar}`, which is slightly longer but which avoids the behavior change.

  • Allow keyof/readonly/infer in TypeScript index signatures (#1859)

    This release fixes a bug that prevented these keywords from being used as names in index signatures. The following TypeScript code was previously rejected, but is now accepted:

    interface Foo {
      [keyof: string]: number
    }

    This fix was contributed by @​magic-akari.

  • Avoid warning about import.meta if it's replaced (#1868)

    It's possible to replace the import.meta expression using the --define: feature. Previously doing that still warned that the import.meta syntax was not supported when targeting ES5. With this release, there will no longer be a warning in this case.

Commits
  • 1baacc8 publish 0.14.6 to npm
  • c3182c4 fix bugs introduced by #1859
  • f780076 fix(parser): allow Identifier keyof, readonly, infer in TypeScriptObjec...
  • 58a6488 fix #1862: add a missing "break" statement
  • 8187e73 fix #1868: remove "import.meta" warning sometimes
  • 8244508 minify unused ${x}y into ${x} instead of x+""
  • eef9253 fold addition of empty string and string
  • db27ce8 fix #1853: remove certain unused template literals
  • 517d75f rename a confusingly named function
  • c89c502 fix a minifier bug with bigint literals
  • See full diff in compare view

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)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code labels Dec 20, 2021
@codecov-commenter
Copy link

Codecov Report

Merging #25 (8fc0cc4) into master (2eb6845) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##            master       #25   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines           48        48           
  Branches        10        10           
=========================================
  Hits            48        48           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2eb6845...8fc0cc4. Read the comment docs.

Bumps [esbuild](https://github.com/evanw/esbuild) from 0.14.5 to 0.14.6.
- [Release notes](https://github.com/evanw/esbuild/releases)
- [Changelog](https://github.com/evanw/esbuild/blob/master/CHANGELOG.md)
- [Commits](evanw/esbuild@v0.14.5...v0.14.6)

---
updated-dependencies:
- dependency-name: esbuild
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/esbuild-0.14.6 branch from 8fc0cc4 to f6500db Compare December 20, 2021 14:13
@Aviortheking Aviortheking merged commit 87531f1 into master Dec 20, 2021
@Aviortheking Aviortheking deleted the dependabot/npm_and_yarn/esbuild-0.14.6 branch December 20, 2021 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants