Skip to content
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

feat: NormalModuleFactory and resolveForScheme hook #2356

Merged
merged 9 commits into from
Mar 21, 2023
Merged

Conversation

IWANABETHATGUY
Copy link
Contributor

@IWANABETHATGUY IWANABETHATGUY commented Mar 20, 2023

Summary

  1. Passing NormalModuleFactory parameter in thisCompilation hook.
  2. Basically finishes NMF.hooks.resolveForScheme except for the second param, because our data structure is not aligned to webpack https://github.com/webpack/webpack/blob/main/lib/NormalModuleFactory.js#L50-L64, but it is enough for angular usage.

Related issue (if exists)

  1. resolved Passing NormalModuleFactory parameter in thisCompilation hook. #2377
  2. resolved resolveForScheme hook of NormalModuleFactory #2375

Types of changes

  • Docs change / Dependency upgrade
  • Bug fix
  • New feature / Improvement
  • Refactoring
  • Breaking change

Checklist

  • I have added changeset via pnpm run changeset.
  • I have added tests to cover my changes.

@changeset-bot
Copy link

changeset-bot bot commented Mar 20, 2023

🦋 Changeset detected

Latest commit: 4660372

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 16 packages
Name Type
@rspack/binding Patch
@rspack/core Patch
@rspack/postcss-loader Patch
@rspack/cli Patch
@rspack/dev-middleware Patch
@rspack/dev-server Patch
@rspack/plugin-html Patch
benchmarkcase-rspack-react-refresh Patch
@rspack/dev-client Patch
@rspack/plugin-minify Patch
@rspack/plugin-node-polyfill Patch
@rspack/binding-darwin-arm64 Patch
@rspack/binding-darwin-x64 Patch
@rspack/binding-linux-x64-gnu Patch
@rspack/binding-win32-x64-msvc Patch
@rspack/fs Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the team The issue/pr is created by the member of Rspack. label Mar 20, 2023
@IWANABETHATGUY IWANABETHATGUY changed the title Feat/nmf hook feat: nmf hook Mar 20, 2023
@zackarychapple
Copy link
Contributor

Will need to test this with #2152 in order to address #2099.

@IWANABETHATGUY
Copy link
Contributor Author

already tested by #2152 (comment)

ahabhgk
ahabhgk previously approved these changes Mar 21, 2023
h-a-n-a
h-a-n-a previously approved these changes Mar 21, 2023
@IWANABETHATGUY IWANABETHATGUY dismissed stale reviews from h-a-n-a and ahabhgk via 449f5fa March 21, 2023 09:02
@IWANABETHATGUY IWANABETHATGUY changed the title feat: nmf hook feat: NormalModuleFactory and resolveForScheme hook Mar 21, 2023
@hardfist
Copy link
Contributor

we need take benchmark back before merge this MR

@IWANABETHATGUY
Copy link
Contributor Author

!bench

@github-actions
Copy link
Contributor

Benchmark Results

group                                                 baseline                               pr
-----                                                 --------                               --
criterion_benchmark/ten_copy_of_threejs               1.02       2.7±0.17s        ? ?/sec    1.00       2.6±0.10s        ? ?/sec
high_cost_benchmark/ten_copy_of_threejs_production    1.00      10.5±0.27s        ? ?/sec    1.01      10.7±0.34s        ? ?/sec

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team The issue/pr is created by the member of Rspack.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Passing NormalModuleFactory parameter in thisCompilation hook. resolveForScheme hook of NormalModuleFactory
5 participants