unjs / knitwork

🧶 Utilities to generate safe JavaScript code.
MIT License
270 stars 10 forks source link

chore(deps): update all non-major dependencies #55

Closed renovate[bot] closed 1 year ago

renovate[bot] commented 1 year ago

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@vitest/coverage-c8 ^0.25.5 -> ^0.25.6 age adoption passing confidence
esbuild ^0.16.1 -> ^0.16.2 age adoption passing confidence
vitest ^0.25.5 -> ^0.25.6 age adoption passing confidence

Release Notes

vitest-dev/vitest ### [`v0.25.6`](https://togithub.com/vitest-dev/vitest/releases/tag/v0.25.6) [Compare Source](https://togithub.com/vitest-dev/vitest/compare/v0.25.5...v0.25.6) #####    🐞 Bug Fixes - Expected reversed with actual  -  by [@​poyoho](https://togithub.com/poyoho) in [https://github.com/vitest-dev/vitest/issues/2460](https://togithub.com/vitest-dev/vitest/issues/2460) [(f02c9)](https://togithub.com/vitest-dev/vitest/commit/f02c9828) - Try to resolve id, if relative path is provided  -  by [@​sheremet-va](https://togithub.com/sheremet-va) in [https://github.com/vitest-dev/vitest/issues/2461](https://togithub.com/vitest-dev/vitest/issues/2461) [(e9cb4)](https://togithub.com/vitest-dev/vitest/commit/e9cb4136) #####     [View changes on GitHub](https://togithub.com/vitest-dev/vitest/compare/v0.25.5...v0.25.6)
evanw/esbuild ### [`v0.16.2`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#​0162) [Compare Source](https://togithub.com/evanw/esbuild/compare/v0.16.1...v0.16.2) - Fix `process.env.NODE_ENV` substitution when transforming ([#​2718](https://togithub.com/evanw/esbuild/issues/2718)) Version 0.16.0 introduced an unintentional regression that caused `process.env.NODE_ENV` to be automatically substituted with either `"development"` or `"production"` when using esbuild's `transform` API. This substitution is a necessary feature of esbuild's `build` API because the React framework crashes when you bundle it without doing this. But the `transform` API is typically used as part of a larger build pipeline so the benefit of esbuild doing this automatically is not as clear, and esbuild previously didn't do this. However, version 0.16.0 switched the default value of the `platform` setting for the `transform` API from `neutral` to `browser`, both to align it with esbuild's documentation (which says `browser` is the default value) and because escaping the `` character sequence is now tied to the `browser` platform (see the release notes for version 0.16.0 for details). That accidentally enabled automatic substitution of `process.env.NODE_ENV` because esbuild always did that for code meant for the browser. To fix this regression, esbuild will now only automatically substitute `process.env.NODE_ENV` when using the `build` API. - Prevent `define` from substituting constants into assignment position ([#​2719](https://togithub.com/evanw/esbuild/issues/2719)) The `define` feature lets you replace certain expressions with constants. For example, you could use it to replace references to the global property reference `window.DEBUG` with `false` at compile time, which can then potentially help esbuild remove unused code from your bundle. It's similar to [DefinePlugin](https://webpack.js.org/plugins/define-plugin/) in Webpack. However, if you write code such as `window.DEBUG = true` and then defined `window.DEBUG` to `false`, esbuild previously generated the output `false = true` which is a syntax error in JavaScript. This behavior is not typically a problem because it doesn't make sense to substitute `window.DEBUG` with a constant if its value changes at run-time (Webpack's `DefinePlugin` also generates `false = true` in this case). But it can be alarming to have esbuild generate code with a syntax error. So with this release, esbuild will no longer substitute `define` constants into assignment position to avoid generating code with a syntax error. Instead esbuild will generate a warning, which currently looks like this: ▲ [WARNING] Suspicious assignment to defined constant "window.DEBUG" [assign-to-define] example.js:1:0: 1 │ window.DEBUG = true ╵ ~~~~~~~~~~~~ The expression "window.DEBUG" has been configured to be replaced with a constant using the "define" feature. If this expression is supposed to be a compile-time constant, then it doesn't make sense to assign to it here. Or if this expression is supposed to change at run-time, this "define" substitution should be removed. - Fix a regression with `npm install --no-optional` ([#​2720](https://togithub.com/evanw/esbuild/issues/2720)) Normally when you install esbuild with `npm install`, npm itself is the tool that downloads the correct binary executable for the current platform. This happens because of how esbuild's primary package uses npm's `optionalDependencies` feature. However, if you deliberately disable this with `npm install --no-optional` then esbuild's install script will attempt to repair the installation by manually downloading and extracting the binary executable from the package that was supposed to be installed. The change in version 0.16.0 to move esbuild's nested packages into the `@esbuild/` scope unintentionally broke this logic because of how npm's URL structure is different for scoped packages vs. normal packages. It was actually already broken for a few platforms earlier because esbuild already had packages for some platforms in the `@esbuild/` scope, but I didn't discover this then because esbuild's integration tests aren't run on all platforms. Anyway, this release contains some changes to the install script that should hopefully get this scenario working again.

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.



This PR has been generated by Mend Renovate. View repository job log here.

codecov[bot] commented 1 year ago

Codecov Report

Merging #55 (b5c1c04) into main (54074c0) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff           @@
##             main      #55   +/-   ##
=======================================
  Coverage   95.57%   95.57%           
=======================================
  Files           7        7           
  Lines         226      226           
  Branches       72       72           
=======================================
  Hits          216      216           
  Misses         10       10           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.