Skip to content

[Snyk] Upgrade esbuild from 0.17.19 to 0.18.0#1

Open
slumericanBx wants to merge 1 commit intomainfrom
snyk-upgrade-eb4a09e269ad1025ae215ea5aef2f348
Open

[Snyk] Upgrade esbuild from 0.17.19 to 0.18.0#1
slumericanBx wants to merge 1 commit intomainfrom
snyk-upgrade-eb4a09e269ad1025ae215ea5aef2f348

Conversation

@slumericanBx
Copy link
Owner

This PR was automatically created by Snyk using the credentials of a real user.


Snyk has created this PR to upgrade esbuild from 0.17.19 to 0.18.0.

ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.


  • The recommended version is 1 version ahead of your current version.
  • The recommended version was released 23 days ago, on 2023-06-09.
Release notes
Package name: esbuild
  • 0.18.0 - 2023-06-09
    Read more
  • 0.17.19 - 2023-05-13
    • Fix CSS transform bugs with nested selectors that start with a combinator (#3096)

      This release fixes several bugs regarding transforming nested CSS into non-nested CSS for older browsers. The bugs were due to lack of test coverage for nested selectors with more than one compound selector where they all start with the same combinator. Here's what some problematic cases look like before and after these fixes:

      / Original code */
      .foo {
      > &a,
      > &b {
      color: red;
      }
      }
      .bar {
      > &a,
      + &b {
      color: green;
      }
      }

      /* Old output (with --target=chrome90) */
      .foo :is(> .fooa, > .foob) {
      color: red;
      }
      .bar :is(> .bara, + .barb) {
      color: green;
      }

      /* New output (with --target=chrome90) */
      .foo > :is(a.foo, b.foo) {
      color: red;
      }
      .bar > a.bar,
      .bar + b.bar {
      color: green;
      }

    • Fix bug with TypeScript parsing of instantiation expressions followed by = (#3111)

      This release fixes esbuild's TypeScript-to-JavaScript conversion code in the case where a potential instantiation expression is followed immediately by a = token (such that the trailing > becomes a >= token). Previously esbuild considered that to still be an instantiation expression, but the official TypeScript compiler considered it to be a >= operator instead. This release changes esbuild's interpretation to match TypeScript. This edge case currently appears to be problematic for other TypeScript-to-JavaScript converters as well:

      Original code TypeScript esbuild 0.17.18 esbuild 0.17.19 Sucrase Babel
      x<y>=a<b<c>>() x<y>=a(); x=a(); x<y>=a(); x=a() Invalid left-hand side in assignment expression
    • Avoid removing unrecognized directives from the directive prologue when minifying (#3115)

      The directive prologue in JavaScript is a sequence of top-level string expressions that come before your code. The only directives that JavaScript engines currently recognize are use strict and sometimes use asm. However, the people behind React have made up their own directive for their own custom dialect of JavaScript. Previously esbuild only preserved the use strict directive when minifying, although you could still write React JavaScript with esbuild using something like --banner:js="'your directive here';". With this release, you can now put arbitrary directives in the entry point and esbuild will preserve them in its minified output:

      // Original code
      'use wtf'; console.log(123)

      // Old output (with --minify)
      console.log(123);

      // New output (with --minify)
      "use wtf";console.log(123);

      Note that this means esbuild will no longer remove certain stray top-level strings when minifying. This behavior is an intentional change because these stray top-level strings are actually part of the directive prologue, and could potentially have semantics assigned to them (as was the case with React).

    • Improved minification of binary shift operators

      With this release, esbuild's minifier will now evaluate the << and >>> operators if the resulting code would be shorter:

      // Original code
      console.log(10 << 10, 10 << 20, -123 >>> 5, -123 >>> 10);

      // Old output (with --minify)
      console.log(10<<10,10<<20,-123>>>5,-123>>>10);

      // New output (with --minify)
      console.log(10240,10<<20,-123>>>5,4194303);

from esbuild GitHub release notes
Commit messages
Package name: esbuild

Compare


Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.

For more information:

🧐 View latest project report

🛠 Adjust upgrade PR settings

🔕 Ignore this dependency or unsubscribe from future upgrade PRs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment