Skip to content

feat: support origin.loc on chunkgroup#10188

Merged
LingyuCoder merged 1 commit intomainfrom
feat/chunkgroup-origin-loc
Apr 27, 2025
Merged

feat: support origin.loc on chunkgroup#10188
LingyuCoder merged 1 commit intomainfrom
feat/chunkgroup-origin-loc

Conversation

@LingyuCoder
Copy link
Contributor

Summary

close #7922

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@LingyuCoder LingyuCoder requested review from SyMind and Copilot April 25, 2025 11:41
@github-actions github-actions bot added team The issue/pr is created by the member of Rspack. release: feature release: feature related release(mr only) labels Apr 25, 2025
@netlify
Copy link

netlify bot commented Apr 25, 2025

Deploy Preview for rspack ready!

Name Link
🔨 Latest commit 89e52c3
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/680da562f1f42c00085e973c
😎 Deploy Preview https://deploy-preview-10188--rspack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for the new origin.loc property in ChunkGroup by updating type definitions, serialization logic, and API documentation.

  • Enable origin.loc parsing in the ChunkGroup getter
  • Update API documentation to reflect the new structure for loc
  • Add Serialize derivations and update node binding handling for origin.loc

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

File Description
packages/rspack/src/ChunkGroup.ts Added loc conversion using JSON.parse for origin.loc
packages/rspack/etc/core.api.md Updated documentation for the new loc field
crates/rspack_core/src/dependency/dependency_location.rs Added Serialize to dependency location types
crates/node_binding/src/chunk_group.rs Updated origin.loc handling and JSON serialization

@LingyuCoder LingyuCoder enabled auto-merge (squash) April 25, 2025 11:55
@codspeed-hq
Copy link

codspeed-hq bot commented Apr 25, 2025

CodSpeed Performance Report

Merging #10188 will not alter performance

Comparing feat/chunkgroup-origin-loc (89e52c3) with main (eff503e)

🎉 Hooray! codspeed-node just leveled up to 4.0.1!

A heads-up, this is a breaking change and it might affect your current performance baseline a bit. But here's the exciting part - it's packed with new, cool features and promises improved result stability 🥳!
Curious about what's new? Visit our releases page to delve into all the awesome details about this new version.

Summary

✅ 11 untouched benchmarks

@SyMind
Copy link
Member

SyMind commented Apr 27, 2025

Using napi object to implement this without json serialization and deserialization.

@LingyuCoder LingyuCoder force-pushed the feat/chunkgroup-origin-loc branch from 4735617 to 89e52c3 Compare April 27, 2025 03:32
@LingyuCoder LingyuCoder merged commit f70ead4 into main Apr 27, 2025
34 checks passed
@LingyuCoder LingyuCoder deleted the feat/chunkgroup-origin-loc branch April 27, 2025 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: feature release: feature related release(mr only) team The issue/pr is created by the member of Rspack.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Add loc to chunkGroup.origins[] OR expose import statement source/comments

3 participants