teknologi-umum / graphene

Lighter Carbon alternative made with Shiki
MIT License
27 stars 10 forks source link

Bump esbuild from 0.13.10 to 0.14.2 in /backend #107

Closed dependabot[bot] closed 2 years ago

dependabot[bot] commented 2 years ago

Bumps esbuild from 0.13.10 to 0.14.2.

Release notes

Sourced from esbuild's releases.

v0.14.2

  • Add [ext] placeholder for path templates (#1799)

    This release adds the [ext] placeholder to the --entry-names=, --chunk-names=, and --asset-names= configuration options. The [ext] placeholder takes the value of the file extension without the leading ., and can be used to place output files with different file extensions into different folders. For example, --asset-names=assets/[ext]/[name]-[hash] might generate an output path of assets/png/image-LSAMBFUD.png.

    This feature was contributed by @​LukeSheard.

  • Disable star-to-clause transform for external imports (#1801)

    When bundling is enabled, esbuild automatically transforms import * as x from 'y'; x.z() into import {z} as 'y'; z() to improve tree shaking. This avoids needing to create the import namespace object x if it's unnecessary, which can result in the removal of large amounts of unused code. However, this transform shouldn't be done for external imports because that incorrectly changes the semantics of the import. If the export z doesn't exist in the previous example, the value x.z is a property access that is undefined at run-time, but the value z is an import error that will prevent the code from running entirely. This release fixes the problem by avoiding doing this transform for external imports:

    // Original code
    import * as x from 'y';
    x.z();
    

    // Old output (with --bundle --format=esm --external:y) import { z } from "y"; z();

    // New output (with --bundle --format=esm --external:y) import * as x from "y"; x.z();

  • Disable calc() transform for numbers with many fractional digits (#1821)

    Version 0.13.12 introduced simplification of calc() expressions in CSS when minifying. For example, calc(100% / 4) turns into 25%. However, this is problematic for numbers with many fractional digits because either the number is printed with reduced precision, which is inaccurate, or the number is printed with full precision, which could be longer than the original expression. For example, turning calc(100% / 3) into 33.33333% is inaccurate and turning it into 33.333333333333336% likely isn't desired. In this release, minification of calc() is now disabled when any number in the result cannot be represented to full precision with at most five fractional digits.

  • Fix an edge case with catch scope handling (#1812)

    This release fixes a subtle edge case with catch scope and destructuring assignment. Identifiers in computed properties and/or default values inside the destructuring binding pattern should reference the outer scope, not the inner scope. The fix was to split the destructuring pattern into its own scope, separate from the catch body. Here's an example of code that was affected by this edge case:

    // Original code
    let foo = 1
    try {
      throw ['a', 'b']
    } catch ({ [foo]: y }) {
      let foo = 2
      assert(y === 'b')
    }
    

    // Old output (with --minify) let foo=1;try{throw["a","b"]}catch({[o]:t}){let o=2;assert(t==="b")}

    // New output (with --minify) let foo=1;try{throw["a","b"]}catch({[foo]:t}){let o=2;assert(t==="b")}

... (truncated)

Changelog

Sourced from esbuild's changelog.

0.14.2

  • Add [ext] placeholder for path templates (#1799)

    This release adds the [ext] placeholder to the --entry-names=, --chunk-names=, and --asset-names= configuration options. The [ext] placeholder takes the value of the file extension without the leading ., and can be used to place output files with different file extensions into different folders. For example, --asset-names=assets/[ext]/[name]-[hash] might generate an output path of assets/png/image-LSAMBFUD.png.

    This feature was contributed by @​LukeSheard.

  • Disable star-to-clause transform for external imports (#1801)

    When bundling is enabled, esbuild automatically transforms import * as x from 'y'; x.z() into import {z} as 'y'; z() to improve tree shaking. This avoids needing to create the import namespace object x if it's unnecessary, which can result in the removal of large amounts of unused code. However, this transform shouldn't be done for external imports because that incorrectly changes the semantics of the import. If the export z doesn't exist in the previous example, the value x.z is a property access that is undefined at run-time, but the value z is an import error that will prevent the code from running entirely. This release fixes the problem by avoiding doing this transform for external imports:

    // Original code
    import * as x from 'y';
    x.z();
    

    // Old output (with --bundle --format=esm --external:y) import { z } from "y"; z();

    // New output (with --bundle --format=esm --external:y) import * as x from "y"; x.z();

  • Disable calc() transform for numbers with many fractional digits (#1821)

    Version 0.13.12 introduced simplification of calc() expressions in CSS when minifying. For example, calc(100% / 4) turns into 25%. However, this is problematic for numbers with many fractional digits because either the number is printed with reduced precision, which is inaccurate, or the number is printed with full precision, which could be longer than the original expression. For example, turning calc(100% / 3) into 33.33333% is inaccurate and turning it into 33.333333333333336% likely isn't desired. In this release, minification of calc() is now disabled when any number in the result cannot be represented to full precision with at most five fractional digits.

  • Fix an edge case with catch scope handling (#1812)

    This release fixes a subtle edge case with catch scope and destructuring assignment. Identifiers in computed properties and/or default values inside the destructuring binding pattern should reference the outer scope, not the inner scope. The fix was to split the destructuring pattern into its own scope, separate from the catch body. Here's an example of code that was affected by this edge case:

    // Original code
    let foo = 1
    try {
      throw ['a', 'b']
    } catch ({ [foo]: y }) {
      let foo = 2
      assert(y === 'b')
    }
    

    // Old output (with --minify) let foo=1;try{throw["a","b"]}catch({[o]:t}){let o=2;assert(t==="b")}

    // New output (with --minify) let foo=1;try{throw["a","b"]}catch({[foo]:t}){let o=2;assert(t==="b")}

... (truncated)

Commits
  • 108719d publish 0.14.2 to npm
  • d1e475e add a note about the go upgrade
  • bfd1c97 more tweaks to makefile
  • 46ab8dc remove accidental "node_modules" dependency
  • 0937255 Makefile: use "$(MAKE)" instead of "make"
  • af05ebd avoid npm for package version assignment
  • 21b7bd5 remove test code evaluation from publish flow
  • 5f43033 publish checks for uncommitted/untracked changes
  • 86974fb add rollup to ci tests
  • be48699 rollup tests: skip "watch" tests to avoid flakes
  • Additional commits viewable 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)