build(deps): bump esbuild and vitest
Bumps esbuild to 0.25.9 and updates ancestor dependency vitest. These dependencies need to be updated together.
Updates esbuild from 0.21.5 to 0.25.9
Release notes
Sourced from esbuild's releases.
v0.25.9
Better support building projects that use Yarn on Windows (#3131, #3663)
With this release, you can now use esbuild to bundle projects that use Yarn Plug'n'Play on Windows on drives other than the
C:drive. The problem was as follows:
- Yarn in Plug'n'Play mode on Windows stores its global module cache on the
C:drive- Some developers put their projects on the
D:drive- Yarn generates relative paths that use
../..to get from the project directory to the cache directory- Windows-style paths don't support directory traversal between drives via
..(soD:\..is justD:)- I didn't have access to a Windows machine for testing this edge case
Yarn works around this edge case by pretending Windows-style paths beginning with
C:\are actually Unix-style paths beginning with/C:/, so the../..path segments are able to navigate across drives inside Yarn's implementation. This was broken for a long time in esbuild but I finally got access to a Windows machine and was able to debug and fix this edge case. So you should now be able to bundle these projects with esbuild.Preserve parentheses around function expressions (#4252)
The V8 JavaScript VM uses parentheses around function expressions as an optimization hint to immediately compile the function. Otherwise the function would be lazily-compiled, which has additional overhead if that function is always called immediately as lazy compilation involves parsing the function twice. You can read V8's blog post about this for more details.
Previously esbuild did not represent parentheses around functions in the AST so they were lost during compilation. With this change, esbuild will now preserve parentheses around function expressions when they are present in the original source code. This means these optimization hints will not be lost when bundling with esbuild. In addition, esbuild will now automatically add this optimization hint to immediately-invoked function expressions. Here's an example:
// Original code const fn0 = () => 0 const fn1 = (() => 1) console.log(fn0, function() { return fn1() }())// Old output
const fn0 = () => 0;
const fn1 = () => 1;
console.log(fn0, function() {
return fn1();
}());// New output
const fn0 = () => 0;
const fn1 = (() => 1);
console.log(fn0, (function() {
return fn1();
})());
Note that you do not want to wrap all function expressions in parentheses. This optimization hint should only be used for functions that are called on initial load. Using this hint for functions that are not called on initial load will unnecessarily delay the initial load. Again, see V8's blog post linked above for details.
Update Go from 1.23.10 to 1.23.12 (#4257, #4258)
This should have no effect on existing code as this version change does not change Go's operating system support. It may remove certain false positive reports (specifically CVE-2025-4674 and CVE-2025-47907) from vulnerability scanners that only detect which version of the Go compiler esbuild uses.
v0.25.8
Fix another TypeScript parsing edge case (#4248)
This fixes a regression with a change in the previous release that tries to more accurately parse TypeScript arrow functions inside the
?:operator. The regression specifically involves parsing an arrow function containing a#privateidentifier inside the middle of a?:ternary operator inside a class body. This was fixed by propagating private identifier state into the parser clone used to speculatively parse the arrow function body. Here is an example of some affected code:
... (truncated)
Changelog
Sourced from esbuild's changelog.
Changelog: 2024
This changelog documents all esbuild versions published in the year 2024 (versions 0.19.12 through 0.24.2).
0.24.2
Fix regression with
--defineandimport.meta(#4010, #4012, #4013)The previous change in version 0.24.1 to use a more expression-like parser for
definevalues to allow quoted property names introduced a regression that removed the ability to use--define:import.meta=.... Even thoughimportis normally a keyword that can't be used as an identifier, ES modules special-case theimport.metaexpression to behave like an identifier anyway. This change fixes the regression.This fix was contributed by
@sapphi-red.0.24.1
Allow
es2024as a target intsconfig.json(#4004)TypeScript recently added
es2024as a compilation target, so esbuild now supports this in thetargetfield oftsconfig.jsonfiles, such as in the following configuration file:{ "compilerOptions": { "target": "ES2024" } }As a reminder, the only thing that esbuild uses this field for is determining whether or not to use legacy TypeScript behavior for class fields. You can read more in the documentation.
This fix was contributed by
@billyjanitsch.Allow automatic semicolon insertion after
get/setThis change fixes a grammar bug in the parser that incorrectly treated the following code as a syntax error:
class Foo { get *x() {} set *y() {} }The above code will be considered valid starting with this release. This change to esbuild follows a similar change to TypeScript which will allow this syntax starting with TypeScript 5.7.
Allow quoted property names in
--defineand--pure(#4008)The
defineandpureAPI options now accept identifier expressions containing quoted property names. Previously all identifiers in the identifier expression had to be bare identifiers. This change now makes--defineand--pureconsistent with--global-name, which already supported quoted property names. For example, the following is now possible:
... (truncated)
Commits
195e05cpublish 0.25.9 to npm3dac33ffix #3131, fix #3663: yarnpnp + windows + D drive0f2c5c8mock fs now supports multiple volumes on windows100a51esplit out yarnpnp snapshot tests13aace3removeC:assumption from windows snapshot testsf1f413ffix #4252: preserve parentheses around functions1bc8091fix #4257, close #4258: go 1.23.10 => 1.23.12bc52135move the go compiler version togo.versiona0af5d1makefile: useESBUILD_VERSIONconsistently8c71947publish 0.25.8 to npm- Additional commits viewable in compare view
Updates vitest from 1.6.1 to 3.2.4
Release notes
Sourced from vitest's releases.
v3.2.4
🐞 Bug Fixes
- Use correct path for optimisation of strip-literal - by
@mrginglymusin vitest-dev/vitest#8139 (44940)- Print uint and buffer as a simple string - by
@sheremet-vain vitest-dev/vitest#8141 (b86bf)- browser:
- Show a helpful error when spying on an export - by
@sheremet-vain vitest-dev/vitest#8178 (56007)- cli:
vitest run --watchshould be watch-mode - by@AriPerkkioin vitest-dev/vitest#8128 (657e8)- Use absolute path environment on Windows - by
@colinaaain vitest-dev/vitest#8105 (85dc0)- Throw error when
--shard x/<count>exceeds count of test files - by@AriPerkkioin vitest-dev/vitest#8112 (8a18c)- coverage:
- Ignore SCSS in browser mode - by
@sheremet-vain vitest-dev/vitest#8161 (0c3be)- deps:
- Update all non-major dependencies - in vitest-dev/vitest#8123 (93f32)
- expect:
- Handle async errors in expect.soft - by
@lzl0304in vitest-dev/vitest#8145 (68699)- pool:
- Auto-adjust
minWorkerswhen onlymaxWorkersspecified - by@AriPerkkioin vitest-dev/vitest#8110 (14dc0)- reporter:
task.metashould be available in custom reporter's errors - by@AriPerkkioin vitest-dev/vitest#8115 (27df6)- runner:
- Preserve handler wrapping on extend - by
@pengooseDevin vitest-dev/vitest#8153 (a9281)- ui:
- Ensure ui config option works correctly - by
@lzl0304in vitest-dev/vitest#8147 (42eeb)View changes on GitHub
v3.2.3
🚀 Features
- browser: Use base url instead of vitest - by
@sheremet-vain vitest-dev/vitest#8126 (1d8eb)- ui: Show test annotations and metadata in the test report tab - by
@sheremet-vain vitest-dev/vitest#8093 (c69be)🐞 Bug Fixes
- Rerun tests when project's setup file is changed - by
@sheremet-vain vitest-dev/vitest#8097 (0f335)- Revert
expect.anyreturn type - by@sheremet-vain vitest-dev/vitest#8129 (47514)- Run only the name plugin last, not all config plugins - by
@sheremet-vain vitest-dev/vitest#8130 (83862)- pool:
- Throw if user's tests use
process.send()- by@AriPerkkioin vitest-dev/vitest#8125 (dfe81)- runner:
- Fast sequential task updates missing - by
@AriPerkkioin vitest-dev/vitest#8121 (7bd11)- Comments between fixture destructures - by
@AriPerkkioin vitest-dev/vitest#8127 (dc469)- vite-node:
- Unable to handle errors where sourcemap mapping empty - by
@blake-newmanand@hi-ogawain vitest-dev/vitest#8071 (8aa25)View changes on GitHub
v3.2.2
... (truncated)
Commits
c666d14chore: release v3.2.48a18c8efix(cli): throw error when--shard x/\<count>exceeds count of test files (#...8abd7ccchore(deps): updatetinypool(#8174)93f3200fix(deps): update all non-major dependencies (#8123)0c3be6ffix(coverage): ignore SCSS in browser mode (#8161)790bc31chore: update deprecation notice for globs (#8148)c0eae7dchore: update deprecated workspace file log (#8118)14dc072fix(pool): auto-adjustminWorkerswhen onlymaxWorkersspecified (#8110)85dc019fix(cli): use absolute path environment on Windows (#8105)27df68afix(reporter):task.metashould be available in custom reporter's errors (#...- Additional commits viewable in compare view
You can trigger a rebase of this PR by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
-
@dependabot rebasewill rebase this PR -
@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it -
@dependabot mergewill merge this PR after your CI passes on it -
@dependabot squash and mergewill squash and merge this PR after your CI passes on it -
@dependabot cancel mergewill cancel a previously requested merge and block automerging -
@dependabot reopenwill reopen this PR if it is closed -
@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually -
@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency -
@dependabot ignore this major versionwill 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 versionwill 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 dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the Security Alerts page.
Note Automatic rebases have been disabled on this pull request as it has been open for over 30 days.
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
| Diff | Package | Supply Chain Security |
Vulnerability | Quality | Maintenance | License |
|---|---|---|---|---|---|---|
| vitest@1.6.1 ⏵ 3.2.4 |