Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(deps): Bump esbuild from 0.14.54 to 0.19.5 (#26)
Bumps [esbuild](https://github.com/evanw/esbuild) from 0.14.54 to 0.19.5. <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.19.5</h2> <ul> <li> <p>Fix a regression in 0.19.0 regarding <code>paths</code> in <code>tsconfig.json</code> (<a href="https://redirect.github.com/evanw/esbuild/issues/3354">#3354</a>)</p> <p>The fix in esbuild version 0.19.0 to process <code>tsconfig.json</code> aliases before the <code>--packages=external</code> setting unintentionally broke an edge case in esbuild's handling of certain <code>tsconfig.json</code> aliases where there are multiple files with the same name in different directories. This release adjusts esbuild's behavior for this edge case so that it passes while still processing aliases before <code>--packages=external</code>. Please read the linked issue for more details.</p> </li> <li> <p>Fix a CSS <code>font</code> property minification bug (<a href="https://redirect.github.com/evanw/esbuild/issues/3452">#3452</a>)</p> <p>This release fixes a bug where esbuild's CSS minifier didn't insert a space between the font size and the font family in the <code>font</code> CSS shorthand property in the edge case where the original source code didn't already have a space and the leading string token was shortened to an identifier:</p> <pre lang="css"><code>/* Original code */ .foo { font: 16px"Menlo"; } <p>/* Old output (with --minify) */ .foo{font:16pxMenlo}</p> <p>/* New output (with --minify) */ .foo{font:16px Menlo} </code></pre></p> </li> <li> <p>Fix bundling CSS with asset names containing spaces (<a href="https://redirect.github.com/evanw/esbuild/issues/3410">#3410</a>)</p> <p>Assets referenced via CSS <code>url()</code> tokens may cause esbuild to generate invalid output when bundling if the file name contains spaces (e.g. <code>url(image 2.png)</code>). With this release, esbuild will now quote all bundled asset references in <code>url()</code> tokens to avoid this problem. This only affects assets loaded using the <code>file</code> and <code>copy</code> loaders.</p> </li> <li> <p>Fix invalid CSS <code>url()</code> tokens in <code>@import</code> rules (<a href="https://redirect.github.com/evanw/esbuild/issues/3426">#3426</a>)</p> <p>In the future, CSS <code>url()</code> tokens may contain additional stuff after the URL. This is irrelevant today as no CSS specification does this. But esbuild previously had a bug where using these tokens in an <code>@import</code> rule resulted in malformed output. This bug has been fixed.</p> </li> <li> <p>Fix <code>browser</code> + <code>false</code> + <code>type: module</code> in <code>package.json</code> (<a href="https://redirect.github.com/evanw/esbuild/issues/3367">#3367</a>)</p> <p>The <code>browser</code> field in <code>package.json</code> allows you to map a file to <code>false</code> to have it be treated as an empty file when bundling for the browser. However, if <code>package.json</code> contains <code>"type": "module"</code> then all <code>.js</code> files will be considered ESM, not CommonJS. Importing a named import from an empty CommonJS file gives you undefined, but importing a named export from an empty ESM file is a build error. This release changes esbuild's interpretation of these files mapped to <code>false</code> in this situation from ESM to CommonJS to avoid generating build errors for named imports.</p> </li> <li> <p>Fix a bug in top-level await error reporting (<a href="https://redirect.github.com/evanw/esbuild/issues/3400">#3400</a>)</p> <p>Using <code>require()</code> on a file that contains <a href="https://v8.dev/features/top-level-await">top-level await</a> is not allowed because <code>require()</code> must return synchronously and top-level await makes that impossible. You will get a build error if you try to bundle code that does this with esbuild. This release fixes a bug in esbuild's error reporting code for complex cases of this situation involving multiple levels of imports to get to the module containing the top-level await.</p> </li> <li> <p>Update to Unicode 15.1.0</p> <p>The character tables that determine which characters form valid JavaScript identifiers have been updated from Unicode version 15.0.0 to the newly-released Unicode version 15.1.0. I'm not putting an example in the release notes because all of the new characters will likely just show up as little squares since fonts haven't been updated yet. But you can read <a href="https://www.unicode.org/versions/Unicode15.1.0/#Summary">https://www.unicode.org/versions/Unicode15.1.0/#Summary</a> for more information about the changes.</p> <p>This upgrade was contributed by <a href="https://github.com/JLHwung"><code>@JLHwung</code></a>.</p> </li> </ul> <h2>v0.19.4</h2> <ul> <li> <p>Fix printing of JavaScript decorators in tricky cases (<a href="https://redirect.github.com/evanw/esbuild/issues/3396">#3396</a>)</p> <p>This release fixes some bugs where esbuild's pretty-printing of JavaScript decorators could incorrectly produced code with a syntax error. The problem happened because esbuild sometimes substitutes identifiers for other expressions in the pretty-printer itself, but the decision about whether to wrap the expression or not didn't account for this. Here are some examples:</p> <pre lang="js"><code>// Original code import { constant } from './constants.js' </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-2022.md">esbuild's changelog</a>.</em></p> <blockquote> <h1>Changelog: 2022</h1> <p>This changelog documents all esbuild versions published in the year 2022 (versions 0.14.11 through 0.16.12).</p> <h2>0.16.12</h2> <ul> <li> <p>Loader defaults to <code>js</code> for extensionless files (<a href="https://redirect.github.com/evanw/esbuild/issues/2776">#2776</a>)</p> <p>Certain packages contain files without an extension. For example, the <code>yargs</code> package contains the file <code>yargs/yargs</code> which has no extension. Node, Webpack, and Parcel can all understand code that imports <code>yargs/yargs</code> because they assume that the file is JavaScript. However, esbuild was previously unable to understand this code because it relies on the file extension to tell it how to interpret the file. With this release, esbuild will now assume files without an extension are JavaScript files. This can be customized by setting the loader for <code>""</code> (the empty string, representing files without an extension) to another loader. For example, if you want files without an extension to be treated as CSS instead, you can do that like this:</p> <ul> <li> <p>CLI:</p> <pre><code>esbuild --bundle --loader:=css </code></pre> </li> <li> <p>JS:</p> <pre lang="js"><code>esbuild.build({ bundle: true, loader: { '': 'css' }, }) </code></pre> </li> <li> <p>Go:</p> <pre lang="go"><code>api.Build(api.BuildOptions{ Bundle: true, Loader: map[string]api.Loader{"": api.LoaderCSS}, }) </code></pre> </li> </ul> <p>In addition, the <code>"type"</code> field in <code>package.json</code> files now only applies to files with an explicit <code>.js</code>, <code>.jsx</code>, <code>.ts</code>, or <code>.tsx</code> extension. Previously it was incorrectly applied by esbuild to all files that had an extension other than <code>.mjs</code>, <code>.mts</code>, <code>.cjs</code>, or <code>.cts</code> including extensionless files. So for example an extensionless file in a <code>"type": "module"</code> package is now treated as CommonJS instead of ESM.</p> </li> </ul> <h2>0.16.11</h2> <ul> <li> <p>Avoid a syntax error in the presence of direct <code>eval</code> (<a href="https://redirect.github.com/evanw/esbuild/issues/2761">#2761</a>)</p> <p>The behavior of nested <code>function</code> declarations in JavaScript depends on whether the code is run in strict mode or not. It would be problematic if esbuild preserved nested <code>function</code> declarations in its output because then the behavior would depend on whether the output was run in strict mode or not instead of respecting the strict mode behavior of the original source code. To avoid this, esbuild transforms nested <code>function</code> declarations to preserve the intended behavior of the original source code regardless of whether the output is run in strict mode or not:</p> <pre lang="js"><code>// Original code if (true) { function foo() {} console.log(!!foo) foo = null console.log(!!foo) } </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/a7fcc43fdb6b6edc58f781fe96328f4867f4b33e"><code>a7fcc43</code></a> publish 0.19.5 to npm</li> <li><a href="https://github.com/evanw/esbuild/commit/58708094af0ffa53f73c73eb9c0a821e5b6ed778"><code>5870809</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3367">#3367</a>: ignore ESM flag for disabled modules</li> <li><a href="https://github.com/evanw/esbuild/commit/d5f397f6e5dc6dbb70d2d4bbc5cefe725c2c853c"><code>d5f397f</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3354">#3354</a>: <code>tsconfig.json</code> regression with <code>paths</code></li> <li><a href="https://github.com/evanw/esbuild/commit/72b1e8b4b0d14f9774e427079aae00f5e19c73c4"><code>72b1e8b</code></a> resolver: move <code>IsExternal</code> into <code>PathPair</code></li> <li><a href="https://github.com/evanw/esbuild/commit/b0eddeac5018aadd24736e7f9e64444e05e4e0d2"><code>b0eddea</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3400">#3400</a>: bug in top-level await error reporting</li> <li><a href="https://github.com/evanw/esbuild/commit/47fc80bdb3e57d17dff5787589b764f1541f475b"><code>47fc80b</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3426">#3426</a>: improve invalid <code>url()</code> token parsing</li> <li><a href="https://github.com/evanw/esbuild/commit/d6973b938e4622db0f692d6eac846af60f7515e2"><code>d6973b9</code></a> css: fix url token backtracking with leading space</li> <li><a href="https://github.com/evanw/esbuild/commit/30a43ec794a1b71f37c645f1f1b915090d54bf3e"><code>30a43ec</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3410">#3410</a>: quote asset references in url tokens</li> <li><a href="https://github.com/evanw/esbuild/commit/a579bd80c24de9dd2ebce352e378b0f798bb8ba3"><code>a579bd8</code></a> fix <a href="https://redirect.github.com/evanw/esbuild/issues/3452">#3452</a>: insert space in <code>font</code> when minifying</li> <li><a href="https://github.com/evanw/esbuild/commit/cd91337d87e4f53e388a5a66d24e791957165b24"><code>cd91337</code></a> update go 1.20.7 => 1.20.10</li> <li>Additional commits viewable in <a href="https://github.com/evanw/esbuild/compare/v0.14.54...v0.19.5">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.14.54&new-version=0.19.5)](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 show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@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> --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Nara Kasbergen <[email protected]> Co-authored-by: Nara Kasbergen Kwon <[email protected]>
- Loading branch information