New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve performance of hashRegExp lookup #16759
Improve performance of hashRegExp lookup #16759
Conversation
For applications with a very large number of assets, the cost of invoking a single regular expression with many many values in a group becomes very high. By changing to a list of regular expressions (with helper methods for maintaining the original design) we can get a large performance improvement.
For maintainers only:
|
One thing that I was unsure of was whether or not a given asset could be expected to have multiple asset hashes in it's filename. To be defensive against that case, I've designed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@alexander-akait when you are back and available will you look at this? |
@TheLarkInn looks like one last test still flaky: https://github.com/webpack/webpack/actions/runs/4266358978/jobs/7635349344 |
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@aws-sdk/client-cognito-identity-provider](https://togithub.com/aws/aws-sdk-js-v3/tree/main/clients/client-cognito-identity-provider) ([source](https://togithub.com/aws/aws-sdk-js-v3)) | [`3.282.0` -> `3.287.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fclient-cognito-identity-provider/3.282.0/3.287.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@aws-sdk/client-s3](https://togithub.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3) ([source](https://togithub.com/aws/aws-sdk-js-v3)) | [`3.282.0` -> `3.287.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fclient-s3/3.282.0/3.287.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-a11y](https://togithub.com/storybookjs/storybook/tree/main/addons/a11y) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-a11y/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-actions](https://togithub.com/storybookjs/storybook/tree/main/addons/actions) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-actions/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-docs](https://togithub.com/storybookjs/storybook/tree/main/addons/docs) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-docs/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-essentials](https://togithub.com/storybookjs/storybook/tree/main/addons/essentials) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-essentials/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-interactions](https://togithub.com/storybookjs/storybook/tree/main/addons/interactions) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-interactions/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-links](https://togithub.com/storybookjs/storybook/tree/main/addons/links) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-links/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/addon-viewport](https://togithub.com/storybookjs/storybook/tree/main/addons/viewport) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2faddon-viewport/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/nextjs](https://togithub.com/storybookjs/storybook/tree/next/code/frameworks/nextjs) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2fnextjs/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/react](https://togithub.com/storybookjs/storybook/tree/main/app/react) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2freact/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/theming](https://togithub.com/storybookjs/storybook/tree/main/lib/theming) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2ftheming/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@storybook/types](https://togithub.com/storybookjs/storybook/tree/main/code/lib/types) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/@storybook%2ftypes/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@total-typescript/ts-reset](https://togithub.com/total-typescript/ts-reset) | [`0.3.7` -> `0.4.2`](https://renovatebot.com/diffs/npm/@total-typescript%2fts-reset/0.3.7/0.4.2) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [embla-carousel-react](https://www.embla-carousel.com) ([source](https://togithub.com/davidjerleke/embla-carousel)) | [`7.0.9` -> `7.1.0`](https://renovatebot.com/diffs/npm/embla-carousel-react/7.0.9/7.1.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [msw-storybook-addon](https://msw-sb.vercel.app/) ([source](https://togithub.com/mswjs/msw-storybook-addon)) | [`1.7.0` -> `1.8.0`](https://renovatebot.com/diffs/npm/msw-storybook-addon/1.7.0/1.8.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [next-i18next](https://togithub.com/i18next/next-i18next) | [`13.2.1` -> `13.2.2`](https://renovatebot.com/diffs/npm/next-i18next/13.2.1/13.2.2) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [storybook](https://togithub.com/storybookjs/storybook/tree/main/lib/cli) ([source](https://togithub.com/storybookjs/storybook)) | [`7.0.0-beta.62` -> `7.0.0-beta.63`](https://renovatebot.com/diffs/npm/storybook/7.0.0-beta.62/7.0.0-beta.63) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [webpack](https://togithub.com/webpack/webpack) | [`5.75.0` -> `5.76.0`](https://renovatebot.com/diffs/npm/webpack/5.75.0/5.76.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>aws/aws-sdk-js-v3 (@​aws-sdk/client-cognito-identity-provider)</summary> ### [`v3.287.0`](https://togithub.com/aws/aws-sdk-js-v3/blob/HEAD/clients/client-cognito-identity-provider/CHANGELOG.md#​32870-httpsgithubcomawsaws-sdk-js-v3comparev32860v32870-2023-03-08) [Compare Source](https://togithub.com/aws/aws-sdk-js-v3/compare/v3.282.0...v3.287.0) ##### Bug Fixes - **clients:** remove aggregated client from paginators ([#​4496](https://togithub.com/aws/aws-sdk-js-v3/issues/4496)) ([aea457a](https://togithub.com/aws/aws-sdk-js-v3/commit/aea457ab5d4e72939f2f608140d82b60526eb716)) </details> <details> <summary>aws/aws-sdk-js-v3 (@​aws-sdk/client-s3)</summary> ### [`v3.287.0`](https://togithub.com/aws/aws-sdk-js-v3/blob/HEAD/clients/client-s3/CHANGELOG.md#​32870-httpsgithubcomawsaws-sdk-js-v3comparev32860v32870-2023-03-08) [Compare Source](https://togithub.com/aws/aws-sdk-js-v3/compare/v3.282.0...v3.287.0) ##### Bug Fixes - **clients:** remove aggregated client from paginators ([#​4496](https://togithub.com/aws/aws-sdk-js-v3/issues/4496)) ([aea457a](https://togithub.com/aws/aws-sdk-js-v3/commit/aea457ab5d4e72939f2f608140d82b60526eb716)) </details> <details> <summary>storybookjs/storybook</summary> ### [`v7.0.0-beta.63`](https://togithub.com/storybookjs/storybook/blob/HEAD/CHANGELOG.md#​700-beta63-March-9-2023) [Compare Source](https://togithub.com/storybookjs/storybook/compare/v7.0.0-beta.62...v7.0.0-beta.63) ##### Bug Fixes - Story Index: Fix storySort parsing for parameters variable [#​21481](https://togithub.com/storybooks/storybook/pull/21481) - React/Vite: Add some missing types [#​21449](https://togithub.com/storybooks/storybook/pull/21449) - Docs: Cleanup with Promise instead of setTimeout [#​21476](https://togithub.com/storybooks/storybook/pull/21476) - Docs: Re-render MDX files when you fix a thrown error [#​21454](https://togithub.com/storybooks/storybook/pull/21454) - CLI: Fix mdx-to-csf codemod blocks imports [#​21448](https://togithub.com/storybooks/storybook/pull/21448) ##### Maintenance - CLI: Copy tweaks for automigrations [#​21475](https://togithub.com/storybooks/storybook/pull/21475) - CLI: Warn the user when stories glob does not match any file [#​21392](https://togithub.com/storybooks/storybook/pull/21392) - Docs: Use `Of` type in `useOf` argument [#​21442](https://togithub.com/storybooks/storybook/pull/21442) - Telemetry: Is interactive shell [#​21436](https://togithub.com/storybooks/storybook/pull/21436) </details> <details> <summary>total-typescript/ts-reset</summary> ### [`v0.4.2`](https://togithub.com/total-typescript/ts-reset/releases/tag/v0.4.2) #### 0.4.2 ##### Minor Changes - [`ce9db42`](https://togithub.com/total-typescript/ts-reset/commit/ce9db42): Added support for widening in `Array.lastIndexOf`, `Array.indexOf`, `ReadonlyArray.lastIndexOf` and `ReadonlyArray.indexOf`. - [`107dfc2`](https://togithub.com/total-typescript/ts-reset/commit/107dfc2): Changed the array.includes on readonly arrays to NOT be a type predicate. Before this change, this perfectly valid code would not behave correctly. ```ts type Code = 0 | 1 | 2; type SpecificCode = 0 | 1; const currentCode: Code = 0; // Create an empty list of subset type const specificCodeList: ReadonlyArray<SpecificCode> = []; // This will be false, since 0 is not in [] if (specificCodeList.includes(currentCode)) { currentCode; // -> SpecificCode } else { // This branch will be entered, and ts will think z is 2, when it is actually 0 currentCode; // -> 2 } ``` Removing the type predicate brings ts-reset closer towards correctness. - [`4765413`](https://togithub.com/total-typescript/ts-reset/commit/4765413): author: [@​mefechoel](https://togithub.com/mefechoel) Added the `Map.has` rule. Similar to `.includes` or `Set.has()`, `Map.has()` doesn't let you pass members that don't exist in the map's keys: ```ts // BEFORE const userMap = new Map([ ["matt", 0], ["sofia", 1], [2, "waqas"], ] as const); // Argument of type '"bryan"' is not assignable to // parameter of type '"matt" | "sofia" | "waqas"'. userMap.has("bryan"); ``` With the rule enabled, `Map` follows the same semantics as `Set`. ```ts // AFTER import "@​total-typescript/ts-reset/map-has"; const userMap = new Map([ ["matt", 0], ["sofia", 1], [2, "waqas"], ] as const); // .has now takes a string as the argument! userMap.has("bryan"); ``` ##### Patch Changes - [`b15aaa4`](https://togithub.com/total-typescript/ts-reset/commit/b15aaa4): Fixed an oversight with the initial `set-has` implementation by adding support to `ReadonlySet`. ### [`v0.4.1`](https://togithub.com/total-typescript/ts-reset/blob/HEAD/CHANGELOG.md#​041) ##### Patch Changes - No changes, just pushing to fix the previous slightly borked release. ### [`v0.4.0`](https://togithub.com/total-typescript/ts-reset/blob/HEAD/CHANGELOG.md#​040) ##### Minor Changes - [`ce9db42`](https://togithub.com/total-typescript/ts-reset/commit/ce9db42): Added support for widening in `Array.lastIndexOf`, `Array.indexOf`, `ReadonlyArray.lastIndexOf` and `ReadonlyArray.indexOf`. - [`107dfc2`](https://togithub.com/total-typescript/ts-reset/commit/107dfc2): Changed the array.includes on readonly arrays to NOT be a type predicate. Before this change, this perfectly valid code would not behave correctly. ```ts type Code = 0 | 1 | 2; type SpecificCode = 0 | 1; const currentCode: Code = 0; // Create an empty list of subset type const specificCodeList: ReadonlyArray<SpecificCode> = []; // This will be false, since 0 is not in [] if (specificCodeList.includes(currentCode)) { currentCode; // -> SpecificCode } else { // This branch will be entered, and ts will think z is 2, when it is actually 0 currentCode; // -> 2 } ``` Removing the type predicate brings ts-reset closer towards correctness. - [`4765413`](https://togithub.com/total-typescript/ts-reset/commit/4765413): author: [@​mefechoel](https://togithub.com/mefechoel) Added the `Map.has` rule. Similar to `.includes` or `Set.has()`, `Map.has()` doesn't let you pass members that don't exist in the map's keys: ```ts // BEFORE const userMap = new Map([ ["matt", 0], ["sofia", 1], [2, "waqas"], ] as const); // Argument of type '"bryan"' is not assignable to // parameter of type '"matt" | "sofia" | "waqas"'. userMap.has("bryan"); ``` With the rule enabled, `Map` follows the same semantics as `Set`. ```ts // AFTER import "@​total-typescript/ts-reset/map-has"; const userMap = new Map([ ["matt", 0], ["sofia", 1], [2, "waqas"], ] as const); // .has now takes a string as the argument! userMap.has("bryan"); ``` ##### Patch Changes - [`b15aaa4`](https://togithub.com/total-typescript/ts-reset/commit/b15aaa4): Fixed an oversight with the initial `set-has` implementation by adding support to `ReadonlySet`. </details> <details> <summary>davidjerleke/embla-carousel</summary> ### [`v7.1.0`](https://togithub.com/davidjerleke/embla-carousel/releases/tag/v7.1.0) [Compare Source](https://togithub.com/davidjerleke/embla-carousel/compare/v7.0.9...v7.1.0) ###🌟 New features: - \[x] [#​440](https://togithub.com/davidjerleke/embla-carousel/issues/440) - Add [`slides`](https://www.embla-carousel.com/api/options/#slides) & [`container`](https://www.embla-carousel.com/api/options/#container) options. ##### Donations Embla Carousel is an open source MIT licensed project. If you are interested in supporting this project, please consider: - [One-off donation via PayPal](https://www.paypal.com/paypalme/davidjerleke) - [One-off/monthly donations via Ko-fi](https://ko-fi.com/davidjerleke) *** #### What's Changed - Migrate to the latest Gatsby version by [@​davidjerleke](https://togithub.com/davidjerleke) in [davidjerleke/embla-carousel#428 - Docs improvements by [@​davidjerleke](https://togithub.com/davidjerleke) in [davidjerleke/embla-carousel#439 - Add `slides` & `container` options by [@​davidjerleke](https://togithub.com/davidjerleke) in [davidjerleke/embla-carousel#441 **Full Changelog**: davidjerleke/embla-carousel@v7.0.9...v7.1.0 </details> <details> <summary>mswjs/msw-storybook-addon</summary> ### [`v1.8.0`](https://togithub.com/mswjs/msw-storybook-addon/blob/HEAD/packages/msw-addon/CHANGELOG.md#v180-Wed-Mar-08-2023) [Compare Source](https://togithub.com/mswjs/msw-storybook-addon/compare/v1.7.0...v1.8.0) #####🚀 Enhancement - support Storybook 7 [#​102](https://togithub.com/mswjs/msw-storybook-addon/pull/102) ([@​yannbf](https://togithub.com/yannbf)) #####🐛 Bug Fix - Fetch git tags on release workflow [#​103](https://togithub.com/mswjs/msw-storybook-addon/pull/103) ([@​yannbf](https://togithub.com/yannbf)) - Use auto for release management [#​100](https://togithub.com/mswjs/msw-storybook-addon/pull/100) ([@​yannbf](https://togithub.com/yannbf)) - fix: update peer dependency range [#​94](https://togithub.com/mswjs/msw-storybook-addon/pull/94) ([@​rajtslegr](https://togithub.com/rajtslegr)) ##### Authors: 2 - Petr Rajtslegr ([@​rajtslegr](https://togithub.com/rajtslegr)) - Yann Braga ([@​yannbf](https://togithub.com/yannbf)) </details> <details> <summary>i18next/next-i18next</summary> ### [`v13.2.2`](https://togithub.com/i18next/next-i18next/blob/HEAD/CHANGELOG.md#​1322) [Compare Source](https://togithub.com/i18next/next-i18next/compare/v13.2.1...v13.2.2) - pageProps may be undefined on strange setups [#​2109](https://togithub.com/i18next/next-i18next/issues/2109)" </details> <details> <summary>webpack/webpack</summary> ### [`v5.76.0`](https://togithub.com/webpack/webpack/releases/tag/v5.76.0) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.75.0...v5.76.0) #### Bugfixes - Avoid cross-realm object access by [@​Jack-Works](https://togithub.com/Jack-Works) in [webpack/webpack#16500 - Improve hash performance via conditional initialization by [@​lvivski](https://togithub.com/lvivski) in [webpack/webpack#16491 - Serialize `generatedCode` info to fix bug in asset module cache restoration by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16703 - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 #### Features - add `target` to `LoaderContext` type by [@​askoufis](https://togithub.com/askoufis) in [webpack/webpack#16781 #### Security - [CVE-2022-37603](https://togithub.com/advisories/GHSA-3rfm-jhwj-7488) fixed by [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) in [webpack/webpack#16446 #### Repo Changes - Fix HTML5 logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16614 - Replace TypeScript logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16613 - Update actions/cache dependencies by [@​piwysocki](https://togithub.com/piwysocki) in [webpack/webpack#16493 #### New Contributors - [@​Jack-Works](https://togithub.com/Jack-Works) made their first contribution in [webpack/webpack#16500 - [@​lvivski](https://togithub.com/lvivski) made their first contribution in [webpack/webpack#16491 - [@​jakebailey](https://togithub.com/jakebailey) made their first contribution in [webpack/webpack#16614 - [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) made their first contribution in [webpack/webpack#16446 - [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) made their first contribution in [webpack/webpack#16703 - [@​piwysocki](https://togithub.com/piwysocki) made their first contribution in [webpack/webpack#16493 - [@​askoufis](https://togithub.com/askoufis) made their first contribution in [webpack/webpack#16781 **Full Changelog**: webpack/webpack@v5.75.0...v5.76.0 </details> --- ### Configuration📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/weareinreach/InReach). PR-URL: #278 Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@ryanwilsonperkin thanks for this PR! I was thinking of a similar change, while working on #16491, and was very excited to see you making it :) Even generating multiple |
Hey @lvivski thanks for bringing it to my attention. Could you include some information about the format of the hashes that you're replacing and the number and size of assets that you're replacing them in? And are you able to isolate the timeout to this part of the code? |
we're using
~5 runtime assets
Yes, after creating a custom I have just ran your stress-test build from https://github.com/ryanwilsonperkin/webpack-16758
|
I'm getting very different results than you on that stress test build:
|
Sorry, I should have clarified that I wasn't running I wonder if this is
This is generally hard to tell, ranging between several Kb to low hundreds, with about 150Mb generated JS total. But yeah, I think that running multiple small RexExp's is less efficient than a single big one, in our case, because of the total number and size of the files. While initialization time might be longer for a big regex, subsequent comparisons are faster with only a single pass through the each file/string. When I was investigating perf for #16491 I wasn't able to create a test setup that would be able to re-create the same level of memory pressure, that our production build has. |
I've created a setup with random strings and maybe there will be a difference on
|
@alexander-akait @TheLarkInn could we test this one more time.. problem here is that if you have small amount of chunks (not a 3000 as in @ryanwilsonperkin example maybe if you have vice versa setup => a lot of small chunks, this give some performance benefits. Also I guess this is very Node.js performance related thing, so it could really depends on Node.js version |
I've got access to a powerful Intel-based machine through work and can confirm what you're seeing:
|
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@aws-sdk/client-cognito-identity-provider](https://togithub.com/aws/aws-sdk-js-v3/tree/main/clients/client-cognito-identity-provider) ([source](https://togithub.com/aws/aws-sdk-js-v3)) | [`3.288.0` -> `3.289.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fclient-cognito-identity-provider/3.288.0/3.289.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@aws-sdk/client-s3](https://togithub.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3) ([source](https://togithub.com/aws/aws-sdk-js-v3)) | [`3.288.0` -> `3.289.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fclient-s3/3.288.0/3.289.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@trpc/client](https://trpc.io) ([source](https://togithub.com/trpc/trpc)) | [`10.14.1` -> `10.15.0`](https://renovatebot.com/diffs/npm/@trpc%2fclient/10.14.1/10.15.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@trpc/next](https://trpc.io) ([source](https://togithub.com/trpc/trpc)) | [`10.14.1` -> `10.15.0`](https://renovatebot.com/diffs/npm/@trpc%2fnext/10.14.1/10.15.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@trpc/react-query](https://trpc.io) ([source](https://togithub.com/trpc/trpc)) | [`10.14.1` -> `10.15.0`](https://renovatebot.com/diffs/npm/@trpc%2freact-query/10.14.1/10.15.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [@trpc/server](https://trpc.io) ([source](https://togithub.com/trpc/trpc)) | [`10.14.1` -> `10.15.0`](https://renovatebot.com/diffs/npm/@trpc%2fserver/10.14.1/10.15.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [dotenv-cli](https://togithub.com/entropitor/dotenv-cli) | [`7.0.0` -> `7.1.0`](https://renovatebot.com/diffs/npm/dotenv-cli/7.0.0/7.1.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [eslint](https://eslint.org) ([source](https://togithub.com/eslint/eslint)) | [`8.35.0` -> `8.36.0`](https://renovatebot.com/diffs/npm/eslint/8.35.0/8.36.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [lint-staged](https://togithub.com/okonet/lint-staged) | [`13.1.2` -> `13.2.0`](https://renovatebot.com/diffs/npm/lint-staged/13.1.2/13.2.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [listr2](https://togithub.com/cenk1cenk2/listr2) | [`5.0.7` -> `5.0.8`](https://renovatebot.com/diffs/npm/listr2/5.0.7/5.0.8) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [quicktype-core](https://togithub.com/quicktype/quicktype) | [`23.0.12` -> `23.0.15`](https://renovatebot.com/diffs/npm/quicktype-core/23.0.12/23.0.15) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [tsx](https://togithub.com/esbuild-kit/tsx) | [`3.12.3` -> `3.12.4`](https://renovatebot.com/diffs/npm/tsx/3.12.3/3.12.4) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [webpack](https://togithub.com/webpack/webpack) | [`5.76.0` -> `5.76.1`](https://renovatebot.com/diffs/npm/webpack/5.76.0/5.76.1) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [zod-prisma-types](https://togithub.com/chrishoermann/zod-prisma-types) | [`2.4.0` -> `2.5.0`](https://renovatebot.com/diffs/npm/zod-prisma-types/2.4.0/2.5.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>aws/aws-sdk-js-v3 (@​aws-sdk/client-cognito-identity-provider)</summary> ### [`v3.289.0`](https://togithub.com/aws/aws-sdk-js-v3/blob/HEAD/clients/client-cognito-identity-provider/CHANGELOG.md#​32890-httpsgithubcomawsaws-sdk-js-v3comparev32880v32890-2023-03-10) [Compare Source](https://togithub.com/aws/aws-sdk-js-v3/compare/v3.288.0...v3.289.0) **Note:** Version bump only for package [@​aws-sdk/client-cognito-identity-provider](https://togithub.com/aws-sdk/client-cognito-identity-provider) </details> <details> <summary>aws/aws-sdk-js-v3 (@​aws-sdk/client-s3)</summary> ### [`v3.289.0`](https://togithub.com/aws/aws-sdk-js-v3/blob/HEAD/clients/client-s3/CHANGELOG.md#​32890-httpsgithubcomawsaws-sdk-js-v3comparev32880v32890-2023-03-10) [Compare Source](https://togithub.com/aws/aws-sdk-js-v3/compare/v3.288.0...v3.289.0) **Note:** Version bump only for package [@​aws-sdk/client-s3](https://togithub.com/aws-sdk/client-s3) </details> <details> <summary>trpc/trpc</summary> ### [`v10.15.0`](https://togithub.com/trpc/trpc/releases/tag/v10.15.0) [Compare Source](https://togithub.com/trpc/trpc/compare/v10.14.1...v10.15.0) ##### What's Changed - fix(server): `d.ts`-files not finding `SerializeObject` by [@​KATT](https://togithub.com/KATT) in [trpc/trpc#3974 - feat(server): add shorthand `{}` for sub-routers by [@​Nsttt](https://togithub.com/Nsttt) in [trpc/trpc#3744 ([📚 docs](https://trpc.io/docs/merging-routers#defining-an-inline-sub-router)) ##### New Contributors - [@​arahansen](https://togithub.com/arahansen) made their first contribution in [trpc/trpc#3959 **Full Changelog**: trpc/trpc@v10.14.1...v10.15.0 </details> <details> <summary>entropitor/dotenv-cli</summary> ### [`v7.1.0`](https://togithub.com/entropitor/dotenv-cli/releases/tag/v7.1.0): Allow --no-expand [Compare Source](https://togithub.com/entropitor/dotenv-cli/compare/v7.0.0...v7.1.0) [entropitor/dotenv-cli#86 </details> <details> <summary>eslint/eslint</summary> ### [`v8.36.0`](https://togithub.com/eslint/eslint/releases/tag/v8.36.0) [Compare Source](https://togithub.com/eslint/eslint/compare/v8.35.0...v8.36.0) #### Features - [`c89a485`](https://togithub.com/eslint/eslint/commit/c89a485c49450532ee3db74f2638429f1f37d0dd) feat: Add `checkJSDoc` option to multiline-comment-style ([#​16807](https://togithub.com/eslint/eslint/issues/16807)) (Laurent Cozic) - [`f5f5e11`](https://togithub.com/eslint/eslint/commit/f5f5e11bd5fd3daab9ccae41e270739c836c305e) feat: Serialize parsers/processors in flat config ([#​16944](https://togithub.com/eslint/eslint/issues/16944)) (Nicholas C. Zakas) - [`4799297`](https://togithub.com/eslint/eslint/commit/4799297ea582c81fd1e5623d32a7ddf7a7f3a126) feat: use [@​eslint-community](https://togithub.com/eslint-community) dependencies ([#​16784](https://togithub.com/eslint/eslint/issues/16784)) (Michaël De Boey) #### Bug Fixes - [`92c1943`](https://togithub.com/eslint/eslint/commit/92c1943ba73ea01e87086236e8736539b0eed558) fix: correctly iterate files matched by glob patterns ([#​16831](https://togithub.com/eslint/eslint/issues/16831)) (Nitin Kumar) #### Documentation - [`b98fdd4`](https://togithub.com/eslint/eslint/commit/b98fdd413a3b07b262bfce6f704c1c1bb8582770) docs: Update README (GitHub Actions Bot) - [`caf08ce`](https://togithub.com/eslint/eslint/commit/caf08ce0cc74917f7c0eec92d25fd784dc33ac4d) docs: fix estree link in custom formatters docs ([#​16967](https://togithub.com/eslint/eslint/issues/16967)) (Milos Djermanovic) - [`3398431`](https://togithub.com/eslint/eslint/commit/3398431574b903757bc78b08c8ed36b7b9fce8eb) docs: Custom Parsers cleanup/expansion ([#​16887](https://togithub.com/eslint/eslint/issues/16887)) (Ben Perlmutter) - [`19d3531`](https://togithub.com/eslint/eslint/commit/19d3531d9b54e1004318d28f9a6e18305c5bcc18) docs: Update README (GitHub Actions Bot) - [`b09a512`](https://togithub.com/eslint/eslint/commit/b09a512107249a4eb19ef5a37b0bd672266eafdb) docs: detect and fix broken links ([#​16837](https://togithub.com/eslint/eslint/issues/16837)) (Nitin Kumar) #### Chores - [`602b111`](https://togithub.com/eslint/eslint/commit/602b11121910a97ab2bc4a95a46dd0ccd0a89309) chore: upgrade [@​eslint/js](https://togithub.com/eslint/js)[@​8](https://togithub.com/8).36.0 ([#​16978](https://togithub.com/eslint/eslint/issues/16978)) (Milos Djermanovic) - [`43c2345`](https://togithub.com/eslint/eslint/commit/43c2345c27024aeab6127e6bbfd55c8b70bd317e) chore: package.json update for [@​eslint/js](https://togithub.com/eslint/js) release (ESLint Jenkins) - [`00afb84`](https://togithub.com/eslint/eslint/commit/00afb84e5039874c8745a45c953fceaf0c71c454) chore: upgrade [@​eslint/eslintrc](https://togithub.com/eslint/eslintrc)[@​2](https://togithub.com/2).0.1 ([#​16977](https://togithub.com/eslint/eslint/issues/16977)) (Milos Djermanovic) - [`698c5aa`](https://togithub.com/eslint/eslint/commit/698c5aad50e628ff00281dbc786e42de79834035) chore: upgrade espree@9.5.0 ([#​16976](https://togithub.com/eslint/eslint/issues/16976)) (Milos Djermanovic) - [`75acdd2`](https://togithub.com/eslint/eslint/commit/75acdd21c5ce7024252e9d41ed77d2f30587caac) chore: lint more js files in docs ([#​16964](https://togithub.com/eslint/eslint/issues/16964)) (Milos Djermanovic) - [`89d9844`](https://togithub.com/eslint/eslint/commit/89d9844b3151f09b5b21b6eeeda671009ec301e9) ci: bump actions/add-to-project from 0.4.0 to 0.4.1 ([#​16943](https://togithub.com/eslint/eslint/issues/16943)) (dependabot\[bot]) </details> <details> <summary>okonet/lint-staged</summary> ### [`v13.2.0`](https://togithub.com/okonet/lint-staged/releases/tag/v13.2.0) [Compare Source](https://togithub.com/okonet/lint-staged/compare/c01d9524f6bcec8180e6f870f0c86ae3f77ab76a...v13.2.0) ##### Bug Fixes - **dependencies:** replace `colorette` with `chalk` for better color support detection ([f598725](https://togithub.com/okonet/lint-staged/commit/f5987252ae59537727a93373b59ab47bc2651a2f)) - use index-based stash references for improved MSYS2 compatibility ([#​1270](https://togithub.com/okonet/lint-staged/issues/1270)) ([60fcd99](https://togithub.com/okonet/lint-staged/commit/60fcd99451b88336a05ebbe71cda8909d2733ad7)) ##### Features - version bump only ([#​1275](https://togithub.com/okonet/lint-staged/issues/1275)) ([05fb382](https://togithub.com/okonet/lint-staged/commit/05fb3829faa5437276d98450c34699fecfc8c1c8)) ### [`v13.1.4`](https://togithub.com/okonet/lint-staged/compare/da6da00654248c34e4f7ce94f61d68ee46f177a1...c01d9524f6bcec8180e6f870f0c86ae3f77ab76a) [Compare Source](https://togithub.com/okonet/lint-staged/compare/da6da00654248c34e4f7ce94f61d68ee46f177a1...c01d9524f6bcec8180e6f870f0c86ae3f77ab76a) ### [`v13.1.3`](https://togithub.com/okonet/lint-staged/compare/v13.1.2...da6da00654248c34e4f7ce94f61d68ee46f177a1) [Compare Source](https://togithub.com/okonet/lint-staged/compare/v13.1.2...da6da00654248c34e4f7ce94f61d68ee46f177a1) </details> <details> <summary>cenk1cenk2/listr2</summary> ### [`v5.0.8`](https://togithub.com/cenk1cenk2/listr2/blob/HEAD/CHANGELOG.md#​508-httpsgithubcomcenk1cenk2listr2comparev507v508-2023-03-11) [Compare Source](https://togithub.com/cenk1cenk2/listr2/compare/v5.0.7...v5.0.8) ##### Bug Fixes - render subtasks of the subtasks if parent has no title ([7b443f9](https://togithub.com/cenk1cenk2/listr2/commit/7b443f9c24a48963c9a95b7545f6792b4474a143)), closes [#​663](https://togithub.com/cenk1cenk2/listr2/issues/663) </details> <details> <summary>quicktype/quicktype</summary> ### [`v23.0.15`](https://togithub.com/quicktype/quicktype/compare/ff62e63abd8d23d72934eecc4723fc9e9b87e5bf...bc9d0689cae9a9349b1a8d2f83a5287ee6cfeb3b) [Compare Source](https://togithub.com/quicktype/quicktype/compare/ff62e63abd8d23d72934eecc4723fc9e9b87e5bf...bc9d0689cae9a9349b1a8d2f83a5287ee6cfeb3b) ### [`v23.0.14`](https://togithub.com/quicktype/quicktype/compare/2497e32cf5a380dc4da9db59386b34b2644b71ad...ff62e63abd8d23d72934eecc4723fc9e9b87e5bf) [Compare Source](https://togithub.com/quicktype/quicktype/compare/2497e32cf5a380dc4da9db59386b34b2644b71ad...ff62e63abd8d23d72934eecc4723fc9e9b87e5bf) ### [`v23.0.13`](https://togithub.com/quicktype/quicktype/compare/5c54136b1c9d0cde90449b2e651968079bd88347...2497e32cf5a380dc4da9db59386b34b2644b71ad) [Compare Source](https://togithub.com/quicktype/quicktype/compare/5c54136b1c9d0cde90449b2e651968079bd88347...2497e32cf5a380dc4da9db59386b34b2644b71ad) </details> <details> <summary>esbuild-kit/tsx</summary> ### [`v3.12.4`](https://togithub.com/esbuild-kit/tsx/releases/tag/v3.12.4) [Compare Source](https://togithub.com/esbuild-kit/tsx/compare/v3.12.3...v3.12.4) ##### Bug Fixes - hide relaySignal from `process.listeners()` ([#​194](https://togithub.com/esbuild-kit/tsx/issues/194)) ([b6793b2](https://togithub.com/esbuild-kit/tsx/commit/b6793b2a87327e0540ee97b2ccab46595373463b)) </details> <details> <summary>webpack/webpack</summary> ### [`v5.76.1`](https://togithub.com/webpack/webpack/releases/tag/v5.76.1) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.0...v5.76.1) #### Fixed - Added `assert/strict` built-in to `NodeTargetPlugin` #### Revert - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 </details> <details> <summary>chrishoermann/zod-prisma-types</summary> ### [`v2.5.0`](https://togithub.com/chrishoermann/zod-prisma-types/releases/tag/v2.5.0): 2.5.0 [Compare Source](https://togithub.com/chrishoermann/zod-prisma-types/compare/v2.4.1...v2.5.0) #### What's changed - updated docs with new DecimalJsLike generation - added support for `extendedWhereUnique` preview feature as stated in [#​91](https://togithub.com/chrishoermann/zod-prisma-types/issues/91) **Full Changelog**: chrishoermann/zod-prisma-types@v2.4.1...v2.5.0 ### [`v2.4.1`](https://togithub.com/chrishoermann/zod-prisma-types/releases/tag/v2.4.1): 2.4.1 [Compare Source](https://togithub.com/chrishoermann/zod-prisma-types/compare/v2.4.0...v2.4.1) #### What's changed - fixed issues [#​100](https://togithub.com/chrishoermann/zod-prisma-types/issues/100) [#​99](https://togithub.com/chrishoermann/zod-prisma-types/issues/99) [#​96](https://togithub.com/chrishoermann/zod-prisma-types/issues/96) [#​90](https://togithub.com/chrishoermann/zod-prisma-types/issues/90) **Full Changelog**: chrishoermann/zod-prisma-types@v2.4.0...v2.4.1 </details> --- ### Configuration📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/weareinreach/InReach). PR-URL: #287 Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Bumps [webpack](https://github.com/webpack/webpack) from 5.72.1 to 5.76.0. v5.76.0 Bugfixes Avoid cross-realm object access by @Jack-Works in webpack/webpack#16500 Improve hash performance via conditional initialization by @lvivski in webpack/webpack#16491 Serialize generatedCode info to fix bug in asset module cache restoration by @ryanwilsonperkin in webpack/webpack#16703 Improve performance of hashRegExp lookup by @ryanwilsonperkin in webpack/webpack#16759 Features add target to LoaderContext type by @askoufis in webpack/webpack#16781 Security CVE-2022-37603 fixed by @akhilgkrishnan in webpack/webpack#16446 Repo Changes Fix HTML5 logo in README by @jakebailey in webpack/webpack#16614 Replace TypeScript logo in README by @jakebailey in webpack/webpack#16613 Update actions/cache dependencies by @piwysocki in webpack/webpack#16493 New Contributors @Jack-Works made their first contribution in webpack/webpack#16500 @lvivski made their first contribution in webpack/webpack#16491 @jakebailey made their first contribution in webpack/webpack#16614 @akhilgkrishnan made their first contribution in webpack/webpack#16446 @ryanwilsonperkin made their first contribution in webpack/webpack#16703 @piwysocki made their first contribution in webpack/webpack#16493 @askoufis made their first contribution in webpack/webpack#16781 Full Changelog: webpack/webpack@v5.75.0...v5.76.0 v5.75.0 Bugfixes experiments.* normalize to false when opt-out avoid NaN% show the correct error when using a conflicting chunk name in code HMR code tests existance of window before trying to access it fix eval-nosources-* actually exclude sources fix race condition where no module is returned from processing module fix position of standalong semicolon in runtime code Features add support for @import to extenal CSS when using experimental CSS in node add i64 support to the deprecated WASM implementation Developer Experience expose EnableWasmLoadingPlugin add more typings generate getters instead of readonly properties in typings to allow overriding them ... (truncated) Commits 97b1718 Merge pull request #16781 from askoufis/loader-context-target-type b84efe6 Merge pull request #16759 from ryanwilsonperkin/real-content-hash-regex-perf c98e9e0 Merge pull request #16493 from piwysocki/patch-1 5f34acf feat: Add target to LoaderContext type b7fc4d8 Merge pull request #16703 from ryanwilsonperkin/ryanwilsonperkin/fix-16160 63ea82d Merge branch 'webpack:main' into patch-1 4ba2252 Merge pull request #16446 from akhilgkrishnan/patch-1 1acd635 Merge pull request #16613 from jakebailey/ts-logo 302eb37 Merge pull request #16614 from jakebailey/html5-logo cfdb1df Improve performance of hashRegExp lookup Additional commits viewable in compare view Maintainer changes This version was pushed to npm by evilebottnawi, a new releaser for webpack since your current version. Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Slade Watkins <srw@sladewatkins.net>
Bumps [webpack](https://github.com/webpack/webpack) from 5.72.1 to 5.76.0. v5.76.0 Bugfixes Avoid cross-realm object access by @Jack-Works in webpack/webpack#16500 Improve hash performance via conditional initialization by @lvivski in webpack/webpack#16491 Serialize generatedCode info to fix bug in asset module cache restoration by @ryanwilsonperkin in webpack/webpack#16703 Improve performance of hashRegExp lookup by @ryanwilsonperkin in webpack/webpack#16759 Features add target to LoaderContext type by @askoufis in webpack/webpack#16781 Security CVE-2022-37603 fixed by @akhilgkrishnan in webpack/webpack#16446 Repo Changes Fix HTML5 logo in README by @jakebailey in webpack/webpack#16614 Replace TypeScript logo in README by @jakebailey in webpack/webpack#16613 Update actions/cache dependencies by @piwysocki in webpack/webpack#16493 New Contributors @Jack-Works made their first contribution in webpack/webpack#16500 @lvivski made their first contribution in webpack/webpack#16491 @jakebailey made their first contribution in webpack/webpack#16614 @akhilgkrishnan made their first contribution in webpack/webpack#16446 @ryanwilsonperkin made their first contribution in webpack/webpack#16703 @piwysocki made their first contribution in webpack/webpack#16493 @askoufis made their first contribution in webpack/webpack#16781 Full Changelog: webpack/webpack@v5.75.0...v5.76.0 v5.75.0 Bugfixes experiments.* normalize to false when opt-out avoid NaN% show the correct error when using a conflicting chunk name in code HMR code tests existance of window before trying to access it fix eval-nosources-* actually exclude sources fix race condition where no module is returned from processing module fix position of standalong semicolon in runtime code Features add support for @import to extenal CSS when using experimental CSS in node add i64 support to the deprecated WASM implementation Developer Experience expose EnableWasmLoadingPlugin add more typings generate getters instead of readonly properties in typings to allow overriding them ... (truncated) Commits 97b1718 Merge pull request #16781 from askoufis/loader-context-target-type b84efe6 Merge pull request #16759 from ryanwilsonperkin/real-content-hash-regex-perf c98e9e0 Merge pull request #16493 from piwysocki/patch-1 5f34acf feat: Add target to LoaderContext type b7fc4d8 Merge pull request #16703 from ryanwilsonperkin/ryanwilsonperkin/fix-16160 63ea82d Merge branch 'webpack:main' into patch-1 4ba2252 Merge pull request #16446 from akhilgkrishnan/patch-1 1acd635 Merge pull request #16613 from jakebailey/ts-logo 302eb37 Merge pull request #16614 from jakebailey/html5-logo cfdb1df Improve performance of hashRegExp lookup Additional commits viewable in compare view Maintainer changes This version was pushed to npm by evilebottnawi, a new releaser for webpack since your current version. Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Slade Watkins <srw@sladewatkins.net>
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [webpack](https://togithub.com/webpack/webpack) | [`5.76.0` -> `5.76.2`](https://renovatebot.com/diffs/npm/webpack/5.76.0/5.76.2) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>webpack/webpack</summary> ### [`v5.76.2`](https://togithub.com/webpack/webpack/releases/tag/v5.76.2) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.1...v5.76.2) #### Bugfixes - Fix bug where a missing semicolon in generated bundle output for `publicPathRuntime` would cause concatenated runtime errors by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16811 - Remove redundant semicolons generated in bundle runtime code after `onScriptComplete` function by [@​ahaoboy](https://togithub.com/ahaoboy) in [webpack/webpack#16347 - Fix bug where `RealContentHashPlugin` was not respecting `output.hashSalt`'s ability to cause a force recalculation of `[contenthash]` for emitted assets by [@​dmichon-msft](https://togithub.com/dmichon-msft) [#​16789](https://togithub.com/webpack/webpack/issues/16789) #### Performance - Improve memory and runtime performance of sourcemaps via hoisting Regular Expression literals to stored variables by [@​TheLarkInn](https://togithub.com/TheLarkInn) in [webpack/webpack#15722 - Correct v8 deoptimization in `ModuleGraph` due to instance property declarations occurring outside of constructor by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16830 #### Developer Experience - Improved internal typings to match `webpack-sources` typings for `Source` instances by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16805 - Update repo examples to include missing quotation by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16812 #### New Contributors - [@​ahaoboy](https://togithub.com/ahaoboy) made their first contribution in [webpack/webpack#16347 **Full Changelog**: webpack/webpack@v5.76.1...v5.76.2 ### [`v5.76.1`](https://togithub.com/webpack/webpack/releases/tag/v5.76.1) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.0...v5.76.1) #### Fixed - Added `assert/strict` built-in to `NodeTargetPlugin` #### Revert - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 </details> --- ### Configuration📅 **Schedule**: Branch creation - "monthly" (UTC), Automerge - At any time (no schedule defined).🚦 **Automerge**: Enabled.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/WtfJoke/setup-tectonic). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS4xMC4yIiwidXBkYXRlZEluVmVyIjoiMzUuMTAuMiJ9-->
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [webpack](https://togithub.com/webpack/webpack) | [`5.76.0` -> `5.76.2`](https://renovatebot.com/diffs/npm/webpack/5.76.0/5.76.2) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>webpack/webpack</summary> ### [`v5.76.2`](https://togithub.com/webpack/webpack/releases/tag/v5.76.2) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.1...v5.76.2) #### Bugfixes - Fix bug where a missing semicolon in generated bundle output for `publicPathRuntime` would cause concatenated runtime errors by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16811 - Remove redundant semicolons generated in bundle runtime code after `onScriptComplete` function by [@​ahaoboy](https://togithub.com/ahaoboy) in [webpack/webpack#16347 - Fix bug where `RealContentHashPlugin` was not respecting `output.hashSalt`'s ability to cause a force recalculation of `[contenthash]` for emitted assets by [@​dmichon-msft](https://togithub.com/dmichon-msft) [#​16789](https://togithub.com/webpack/webpack/issues/16789) #### Performance - Improve memory and runtime performance of sourcemaps via hoisting Regular Expression literals to stored variables by [@​TheLarkInn](https://togithub.com/TheLarkInn) in [webpack/webpack#15722 - Correct v8 deoptimization in `ModuleGraph` due to instance property declarations occurring outside of constructor by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16830 #### Developer Experience - Improved internal typings to match `webpack-sources` typings for `Source` instances by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16805 - Update repo examples to include missing quotation by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16812 #### New Contributors - [@​ahaoboy](https://togithub.com/ahaoboy) made their first contribution in [webpack/webpack#16347 **Full Changelog**: webpack/webpack@v5.76.1...v5.76.2 ### [`v5.76.1`](https://togithub.com/webpack/webpack/releases/tag/v5.76.1) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.0...v5.76.1) #### Fixed - Added `assert/strict` built-in to `NodeTargetPlugin` #### Revert - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 </details> --- ### Configuration📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/dooboolab/dooboo-ui). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS4xMC4yIiwidXBkYXRlZEluVmVyIjoiMzUuMTAuMiJ9--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [webpack](https://togithub.com/webpack/webpack) | [`5.75.0` -> `5.76.0`](https://renovatebot.com/diffs/npm/webpack/5.75.0/5.76.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | ### GitHub Vulnerability Alerts #### [CVE-2023-28154](https://nvd.nist.gov/vuln/detail/CVE-2023-28154) Webpack 5 before 5.76.0 does not avoid cross-realm object access. ImportParserPlugin.js mishandles the magic comment feature. An attacker who controls a property of an untrusted object can obtain access to the real global object. --- ### Release Notes <details> <summary>webpack/webpack</summary> ### [`v5.76.0`](https://togithub.com/webpack/webpack/releases/tag/v5.76.0) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.75.0...v5.76.0) #### Bugfixes - Avoid cross-realm object access by [@​Jack-Works](https://togithub.com/Jack-Works) in [webpack/webpack#16500 - Improve hash performance via conditional initialization by [@​lvivski](https://togithub.com/lvivski) in [webpack/webpack#16491 - Serialize `generatedCode` info to fix bug in asset module cache restoration by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16703 - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 #### Features - add `target` to `LoaderContext` type by [@​askoufis](https://togithub.com/askoufis) in [webpack/webpack#16781 #### Security - [CVE-2022-37603](https://togithub.com/advisories/GHSA-3rfm-jhwj-7488) fixed by [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) in [webpack/webpack#16446 #### Repo Changes - Fix HTML5 logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16614 - Replace TypeScript logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16613 - Update actions/cache dependencies by [@​piwysocki](https://togithub.com/piwysocki) in [webpack/webpack#16493 #### New Contributors - [@​Jack-Works](https://togithub.com/Jack-Works) made their first contribution in [webpack/webpack#16500 - [@​lvivski](https://togithub.com/lvivski) made their first contribution in [webpack/webpack#16491 - [@​jakebailey](https://togithub.com/jakebailey) made their first contribution in [webpack/webpack#16614 - [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) made their first contribution in [webpack/webpack#16446 - [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) made their first contribution in [webpack/webpack#16703 - [@​piwysocki](https://togithub.com/piwysocki) made their first contribution in [webpack/webpack#16493 - [@​askoufis](https://togithub.com/askoufis) made their first contribution in [webpack/webpack#16781 **Full Changelog**: webpack/webpack@v5.75.0...v5.76.0 </details> --- ### Configuration📅 **Schedule**: Branch creation - "" in timezone Australia/Sydney, Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/google/osv.dev). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4xNTkuMSIsInVwZGF0ZWRJblZlciI6IjM0LjE1OS4xIn0=-->
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [lit](https://lit.dev/) ([source](https://togithub.com/lit/lit)) | [`2.6.1` -> `2.7.0`](https://renovatebot.com/diffs/npm/lit/2.6.1/2.7.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [mini-css-extract-plugin](https://togithub.com/webpack-contrib/mini-css-extract-plugin) | [`2.7.2` -> `2.7.5`](https://renovatebot.com/diffs/npm/mini-css-extract-plugin/2.7.2/2.7.5) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [sass](https://togithub.com/sass/dart-sass) | [`1.58.3` -> `1.59.3`](https://renovatebot.com/diffs/npm/sass/1.58.3/1.59.3) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [style-loader](https://togithub.com/webpack-contrib/style-loader) | [`3.3.1` -> `3.3.2`](https://renovatebot.com/diffs/npm/style-loader/3.3.1/3.3.2) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [webpack](https://togithub.com/webpack/webpack) | [`5.76.0` -> `5.76.3`](https://renovatebot.com/diffs/npm/webpack/5.76.0/5.76.3) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | | [webpack-dev-server](https://togithub.com/webpack/webpack-dev-server) | [`4.11.1` -> `4.13.1`](https://renovatebot.com/diffs/npm/webpack-dev-server/4.11.1/4.13.1) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>lit/lit</summary> ### [`v2.7.0`](https://togithub.com/lit/lit/blob/HEAD/packages/lit/CHANGELOG.md#​270) [Compare Source](https://togithub.com/lit/lit/compare/lit@2.6.1...lit@2.7.0) ##### Minor Changes - [#​3677](https://togithub.com/lit/lit/pull/3677) [`b95c86e5`](https://togithub.com/lit/lit/commit/b95c86e5ec0e2f6de63a23409b9ec489edb61b86) - \[SSR only] Reflect ARIA attributes onto server rendered Lit elements with attached internals during SSR and remove them upon hydration. - [#​3667](https://togithub.com/lit/lit/pull/3667) [`e00f6f52`](https://togithub.com/lit/lit/commit/e00f6f52199d5dbc08d4c15f62380422e77cde7f) - \[SSR only] Improved how nodes with attribute/property/event/element bindings are rendered in SSR, to avoid adding comments inside of "raw text elements" like `<textarea>`. Fixes [#​3663](https://togithub.com/lit/lit/issues/3663). Note: `@lit-labs/ssr` and `lit-html` must be updated together. ##### Patch Changes - [#​3583](https://togithub.com/lit/lit/pull/3583) [`88a40177`](https://togithub.com/lit/lit/commit/88a40177de9be5d117a21e3da5414bd777872544) - \[SSR only] Add more detail to some hydration errors - Updated dependencies \[[`4d698430`](https://togithub.com/lit/lit/commit/4d698430b38efa49c97b841238b331340af5fef0), [`b95c86e5`](https://togithub.com/lit/lit/commit/b95c86e5ec0e2f6de63a23409b9ec489edb61b86), [`e00f6f52`](https://togithub.com/lit/lit/commit/e00f6f52199d5dbc08d4c15f62380422e77cde7f), [`88a40177`](https://togithub.com/lit/lit/commit/88a40177de9be5d117a21e3da5414bd777872544)]: - lit-html@2.7.0 - lit-element@3.3.0 </details> <details> <summary>webpack-contrib/mini-css-extract-plugin</summary> ### [`v2.7.5`](https://togithub.com/webpack-contrib/mini-css-extract-plugin/blob/HEAD/CHANGELOG.md#​275-httpsgithubcomwebpack-contribmini-css-extract-plugincomparev274v275-2023-03-16) [Compare Source](https://togithub.com/webpack-contrib/mini-css-extract-plugin/compare/v2.7.4...v2.7.5) ### [`v2.7.4`](https://togithub.com/webpack-contrib/mini-css-extract-plugin/blob/HEAD/CHANGELOG.md#​274-httpsgithubcomwebpack-contribmini-css-extract-plugincomparev273v274-2023-03-16) [Compare Source](https://togithub.com/webpack-contrib/mini-css-extract-plugin/compare/v2.7.3...v2.7.4) ### [`v2.7.3`](https://togithub.com/webpack-contrib/mini-css-extract-plugin/blob/HEAD/CHANGELOG.md#​273-httpsgithubcomwebpack-contribmini-css-extract-plugincomparev272v273-2023-03-07) [Compare Source](https://togithub.com/webpack-contrib/mini-css-extract-plugin/compare/v2.7.2...v2.7.3) </details> <details> <summary>sass/dart-sass</summary> ### [`v1.59.3`](https://togithub.com/sass/dart-sass/blob/HEAD/CHANGELOG.md#​1593) [Compare Source](https://togithub.com/sass/dart-sass/compare/1.59.2...1.59.3) - Fix a performance regression introduced in 1.59.0. - The NPM release of 1.59.0 dropped support for Node 12 without actually indicating so in its pubspec. This release temporarily adds back support so that the latest Sass version that declares it supports Node 12 actually does so. However, Node 12 is now end-of-life, so we will drop support for it properly in an upcoming release. ### [`v1.59.2`](https://togithub.com/sass/dart-sass/blob/HEAD/CHANGELOG.md#​1592) [Compare Source](https://togithub.com/sass/dart-sass/compare/1.59.1...1.59.2) - No user-visible changes. ### [`v1.59.1`](https://togithub.com/sass/dart-sass/blob/HEAD/CHANGELOG.md#​1591) [Compare Source](https://togithub.com/sass/dart-sass/compare/1.59.0...1.59.1) - No user-visible changes. ### [`v1.59.0`](https://togithub.com/sass/dart-sass/blob/HEAD/CHANGELOG.md#​1590) [Compare Source](https://togithub.com/sass/dart-sass/compare/1.58.3...1.59.0) ##### Command Line Interface - Added a new `--fatal-deprecation` flag that lets you treat a deprecation warning as an error. You can pass an individual deprecation ID (e.g. `slash-div`) or you can pass a Dart Sass version to treat all deprecations initially emitted in that version or earlier as errors. - New `--future-deprecation` flag that lets you opt into warning for use of certain features that will be deprecated in the future. At the moment, the only option is `--future-deprecation=import`, which will emit warnings for Sass `@import` rules, which are not yet deprecated, but will be in the future. ##### Dart API - New `Deprecation` enum, which contains the different current and future deprecations used by the new CLI flags. - The `compile` methods now take in `fatalDeprecations` and `futureDeprecations` parameters, which work similarly to the CLI flags. </details> <details> <summary>webpack-contrib/style-loader</summary> ### [`v3.3.2`](https://togithub.com/webpack-contrib/style-loader/blob/HEAD/CHANGELOG.md#​332-httpsgithubcomwebpack-contribstyle-loadercomparev331v332-2023-03-13) [Compare Source](https://togithub.com/webpack-contrib/style-loader/compare/v3.3.1...v3.3.2) </details> <details> <summary>webpack/webpack</summary> ### [`v5.76.3`](https://togithub.com/webpack/webpack/releases/tag/v5.76.3) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.2...v5.76.3) #### Bugfixes - Non-javascript files will correctly **not** be imported when using `experiments.outputModule` (ES Module Output) by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16809 - Limit console output progress bar length to 40 when no columns provided by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16810 - Add missing NodeJS Builtin Modules support for `inspector/promises`, `readline/promises`, and `stream/consumers` by [@​ShenHongFei](https://togithub.com/ShenHongFei) in [webpack/webpack#16841 - webpack bin/cli now properly respects `NODE_PATH` env variable by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16808 - Improve typos in `resolveResourceErrorHints` by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16806 - Add missing `loaders` token support to `moduleFilenameTemplate` function call by [@​pgoldberg](https://togithub.com/pgoldberg) in [webpack/webpack#16756 - Add gaurd condition for `enabledLibraryTypes` in internal `ContainerPlugin` by [@​PengBoUESTC](https://togithub.com/PengBoUESTC) in [webpack/webpack#16635 #### New Contributors - [@​ShenHongFei](https://togithub.com/ShenHongFei) made their first contribution in [webpack/webpack#16841 - [@​pgoldberg](https://togithub.com/pgoldberg) made their first contribution in [webpack/webpack#16756 - [@​PengBoUESTC](https://togithub.com/PengBoUESTC) made their first contribution in [webpack/webpack#16635 **Full Changelog**: webpack/webpack@v5.76.2...v5.76.3 ### [`v5.76.2`](https://togithub.com/webpack/webpack/releases/tag/v5.76.2) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.1...v5.76.2) #### Bugfixes - Fix bug where a missing semicolon in generated bundle output for `publicPathRuntime` would cause concatenated runtime errors by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16811 - Remove redundant semicolons generated in bundle runtime code after `onScriptComplete` function by [@​ahaoboy](https://togithub.com/ahaoboy) in [webpack/webpack#16347 - Fix bug where `RealContentHashPlugin` was not respecting `output.hashSalt`'s ability to cause a force recalculation of `[contenthash]` for emitted assets by [@​dmichon-msft](https://togithub.com/dmichon-msft) [#​16789](https://togithub.com/webpack/webpack/issues/16789) #### Performance - Improve memory and runtime performance of sourcemaps via hoisting Regular Expression literals to stored variables by [@​TheLarkInn](https://togithub.com/TheLarkInn) in [webpack/webpack#15722 - Correct v8 deoptimization in `ModuleGraph` due to instance property declarations occurring outside of constructor by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16830 #### Developer Experience - Improved internal typings to match `webpack-sources` typings for `Source` instances by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16805 - Update repo examples to include missing quotation by [@​snitin315](https://togithub.com/snitin315) in [webpack/webpack#16812 #### New Contributors - [@​ahaoboy](https://togithub.com/ahaoboy) made their first contribution in [webpack/webpack#16347 **Full Changelog**: webpack/webpack@v5.76.1...v5.76.2 ### [`v5.76.1`](https://togithub.com/webpack/webpack/releases/tag/v5.76.1) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.76.0...v5.76.1) #### Fixed - Added `assert/strict` built-in to `NodeTargetPlugin` #### Revert - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 </details> <details> <summary>webpack/webpack-dev-server</summary> ### [`v4.13.1`](https://togithub.com/webpack/webpack-dev-server/blob/HEAD/CHANGELOG.md#​4131-httpsgithubcomwebpackwebpack-dev-servercomparev4130v4131-2023-03-18) [Compare Source](https://togithub.com/webpack/webpack-dev-server/compare/v4.13.0...v4.13.1) ### [`v4.13.0`](https://togithub.com/webpack/webpack-dev-server/blob/HEAD/CHANGELOG.md#​4130-httpsgithubcomwebpackwebpack-dev-servercomparev4120v4130-2023-03-17) [Compare Source](https://togithub.com/webpack/webpack-dev-server/compare/v4.12.0...v4.13.0) ##### Features - added `client.overlay.runtimeErrors` option to control runtime errors ([#​4773](https://togithub.com/webpack/webpack-dev-server/issues/4773)) ([dca2366](https://togithub.com/webpack/webpack-dev-server/commit/dca2366e22a262e6052dae060c8b237f4e6fd26b)) ### [`v4.12.0`](https://togithub.com/webpack/webpack-dev-server/blob/HEAD/CHANGELOG.md#​4120-httpsgithubcomwebpackwebpack-dev-servercomparev4111v4120-2023-03-14) [Compare Source](https://togithub.com/webpack/webpack-dev-server/compare/v4.11.1...v4.12.0) ##### Features - allow to set the `sockjs_url` option (only `sockjs`) using the `webSocketServer.options.sockjsUrl` option ([#​4586](https://togithub.com/webpack/webpack-dev-server/issues/4586)) ([69a2fba](https://togithub.com/webpack/webpack-dev-server/commit/69a2fba4e915b4814de1c3cb27930a13dc994945)) - catch runtime error ([#​4605](https://togithub.com/webpack/webpack-dev-server/issues/4605)) ([87a26cf](https://togithub.com/webpack/webpack-dev-server/commit/87a26cf4c1fd9ac8140d345a8520a8d5cb059556)) - improve styles for overlay ([#​4576](https://togithub.com/webpack/webpack-dev-server/issues/4576)) ([791fb85](https://togithub.com/webpack/webpack-dev-server/commit/791fb85931299eea052b3c37d4353d48ea34fa5e)) - open editor when clicking error on overlay ([#​4587](https://togithub.com/webpack/webpack-dev-server/issues/4587)) ([efb2cec](https://togithub.com/webpack/webpack-dev-server/commit/efb2cec3f8acbbe5113aad20529e268c01ac29c2)) ##### Bug Fixes - compatibility with `experiments.buildHttp` ([#​4585](https://togithub.com/webpack/webpack-dev-server/issues/4585)) ([5b846cb](https://togithub.com/webpack/webpack-dev-server/commit/5b846cbe9bfb8444bc7605654fcebf4e87766aa4)) - respect `NODE_PATH` env variable ([#​4581](https://togithub.com/webpack/webpack-dev-server/issues/4581)) ([b857e6f](https://togithub.com/webpack/webpack-dev-server/commit/b857e6fa3b86facc63811438eef17be92dc36dc6)) ##### [4.11.1](https://togithub.com/webpack/webpack-dev-server/compare/v4.11.0...v4.11.1) (2022-09-19) ##### Bug Fixes - respect `client.logging` option for all logs ([#​4572](https://togithub.com/webpack/webpack-dev-server/issues/4572)) ([375835c](https://togithub.com/webpack/webpack-dev-server/commit/375835c926ec03fdfecae9ab1b54fd43b1ff4b31)) </details> --- ### Configuration📅 **Schedule**: Branch creation - "before 6am on wednesday" in timezone Australia/Sydney, Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/google/osv.dev). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4xNTkuMSIsInVwZGF0ZWRJblZlciI6IjM1LjE0LjIifQ==-->
[](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [webpack](https://togithub.com/webpack/webpack) | [`5.75.0` -> `5.76.0`](https://renovatebot.com/diffs/npm/webpack/5.75.0/5.76.0) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | ### GitHub Vulnerability Alerts #### [CVE-2023-28154](https://nvd.nist.gov/vuln/detail/CVE-2023-28154) Webpack 5 before 5.76.0 does not avoid cross-realm object access. ImportParserPlugin.js mishandles the magic comment feature. An attacker who controls a property of an untrusted object can obtain access to the real global object. --- ### Release Notes <details> <summary>webpack/webpack</summary> ### [`v5.76.0`](https://togithub.com/webpack/webpack/releases/tag/v5.76.0) [Compare Source](https://togithub.com/webpack/webpack/compare/v5.75.0...v5.76.0) #### Bugfixes - Avoid cross-realm object access by [@​Jack-Works](https://togithub.com/Jack-Works) in [webpack/webpack#16500 - Improve hash performance via conditional initialization by [@​lvivski](https://togithub.com/lvivski) in [webpack/webpack#16491 - Serialize `generatedCode` info to fix bug in asset module cache restoration by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16703 - Improve performance of `hashRegExp` lookup by [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) in [webpack/webpack#16759 #### Features - add `target` to `LoaderContext` type by [@​askoufis](https://togithub.com/askoufis) in [webpack/webpack#16781 #### Security - [CVE-2022-37603](https://togithub.com/advisories/GHSA-3rfm-jhwj-7488) fixed by [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) in [webpack/webpack#16446 #### Repo Changes - Fix HTML5 logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16614 - Replace TypeScript logo in README by [@​jakebailey](https://togithub.com/jakebailey) in [webpack/webpack#16613 - Update actions/cache dependencies by [@​piwysocki](https://togithub.com/piwysocki) in [webpack/webpack#16493 #### New Contributors - [@​Jack-Works](https://togithub.com/Jack-Works) made their first contribution in [webpack/webpack#16500 - [@​lvivski](https://togithub.com/lvivski) made their first contribution in [webpack/webpack#16491 - [@​jakebailey](https://togithub.com/jakebailey) made their first contribution in [webpack/webpack#16614 - [@​akhilgkrishnan](https://togithub.com/akhilgkrishnan) made their first contribution in [webpack/webpack#16446 - [@​ryanwilsonperkin](https://togithub.com/ryanwilsonperkin) made their first contribution in [webpack/webpack#16703 - [@​piwysocki](https://togithub.com/piwysocki) made their first contribution in [webpack/webpack#16493 - [@​askoufis](https://togithub.com/askoufis) made their first contribution in [webpack/webpack#16781 **Full Changelog**: webpack/webpack@v5.75.0...v5.76.0 </details> --- ### Configuration📅 **Schedule**: Branch creation - "" in timezone Europe/London, Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/guardian/csnx). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4xNjAuMCIsInVwZGF0ZWRJblZlciI6IjM0LjE2MC4wIn0=-->
Bump webpack from 5.75.0 to 5.76.1 Bumps webpack from 5.75.0 to 5.76.1. Release notes Sourced from webpack's releases. v5.76.1 Fixed Added assert/strict built-in to NodeTargetPlugin Revert Improve performance of hashRegExp lookup by @ryanwilsonperkin in webpack/webpack#16759 v5.76.0 Bugfixes Avoid cross-realm object access by @Jack-Works in webpack/webpack#16500 Improve hash performance via conditional initialization by @lvivski in webpack/webpack#16491 Serialize generatedCode info to fix bug in asset module cache restoration by @ryanwilsonperkin in webpack/webpack#16703 Improve performance of hashRegExp lookup by @ryanwilsonperkin in webpack/webpack#16759 Features add target to LoaderContext type by @askoufis in webpack/webpack#16781 Security CVE-2022-37603 fixed by @akhilgkrishnan in webpack/webpack#16446 Repo Changes Fix HTML5 logo in README by @jakebailey in webpack/webpack#16614 Replace TypeScript logo in README by @jakebailey in webpack/webpack#16613 Update actions/cache dependencies by @piwysocki in webpack/webpack#16493 New Contributors @Jack-Works made their first contribution in webpack/webpack#16500 @lvivski made their first contribution in webpack/webpack#16491 @jakebailey made their first contribution in webpack/webpack#16614 @akhilgkrishnan made their first contribution in webpack/webpack#16446 @ryanwilsonperkin made their first contribution in webpack/webpack#16703 @piwysocki made their first contribution in webpack/webpack#16493 @askoufis made their first contribution in webpack/webpack#16781 Full Changelog: webpack/webpack@v5.75.0...v5.76.0 Commits 21be52b Merge pull request #16804 from webpack/chore-patch-release 1cce945 chore(release): 5.76.1 e76ad9e Merge pull request #16803 from ryanwilsonperkin/revert-16759-real-content-has... 52b1b0e Revert "Improve performance of hashRegExp lookup" c989143 Merge pull request #16766 from piranna/patch-1 710eaf4 Merge pull request #16789 from dmichon-msft/contenthash-hashsalt 5d64468 Merge pull request #16792 from webpack/update-version 67af5ec chore(release): 5.76.0 97b1718 Merge pull request #16781 from askoufis/loader-context-target-type b84efe6 Merge pull request #16759 from ryanwilsonperkin/real-content-hash-regex-perf Additional commits viewable in compare view Maintainer changes This version was pushed to npm by evilebottnawi, a new releaser for webpack since your current version. 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) @dependabot use these labels will set the current labels as the default for future PRs for this repo and language @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language You can disable automated security fix PRs for this repo from the Security Alerts page. Reviewed-by: Artem Goncharov
Fixes #16758
For applications with a very large number of assets, the cost of invoking a single regular expression with many many values in a group becomes very high.
By changing to a list of regular expressions (with helper methods for maintaining the original design) we can get a large performance improvement.
A simple way to view the performance difference between these two approaches is with the following short scripts:
Benchmarking these against each other I get the following results:
What kind of change does this PR introduce?
Bugfix, performance
Did you add tests for your changes?
No, given that this is a performance improvement I'm not sure that the test suite is setup to test the difference.
Does this PR introduce a breaking change?
No, hashes remain the same
What needs to be documented once your changes are merged?
N/A