Skip to content

ScopeHoistingPackager: Wrap assets when any ancestor is wrapped#7883

Merged
wbinnssmith merged 8 commits into
v2from
wbinnssmith/multiple-ancestors-wrap
Apr 11, 2022
Merged

ScopeHoistingPackager: Wrap assets when any ancestor is wrapped#7883
wbinnssmith merged 8 commits into
v2from
wbinnssmith/multiple-ancestors-wrap

Conversation

@wbinnssmith

Copy link
Copy Markdown
Contributor

Relying on DFS context is insufficient as it only considers the first ancestor's wrapped state. This performs a dfs downward from each initially wrapped root asset, skipping children as soon as it encounters a currently wrapped asset, ensuring that we don't visit any unnecessary assets further.

Test Plan: Added an integration test. yarn test

@wbinnssmith wbinnssmith force-pushed the wbinnssmith/multiple-ancestors-wrap branch from 53f296a to dd7a39b Compare March 31, 2022 22:24
@wbinnssmith wbinnssmith force-pushed the wbinnssmith/multiple-ancestors-wrap branch from dd7a39b to 344941e Compare March 31, 2022 22:42
@parcel-benchmark

parcel-benchmark commented Mar 31, 2022

Copy link
Copy Markdown

Benchmark Results

Kitchen Sink 🚨

Timings

Description Time Difference
Cold FAILED -0.00ms
Cached FAILED -0.00ms

Cold Bundles

No bundles found, this is probably a failed build...

Cached Bundles

No bundles found, this is probably a failed build...

React HackerNews ✅

Timings

Description Time Difference
Cold 9.75s +177.00ms
Cached 499.00ms +28.00ms ⚠️

Cold Bundles

Bundle Size Difference Time Difference
dist/index.js 485.80kb +519.00b ⚠️ 5.20s +136.00ms

Cached Bundles

Bundle Size Difference Time Difference
dist/index.js 485.80kb +519.00b ⚠️ 5.54s +467.00ms ⚠️
dist/PermalinkedComment.46b19af5.js 4.21kb +0.00b 5.54s +466.00ms ⚠️
dist/UserProfile.f8cd7884.js 1.57kb +0.00b 5.54s +467.00ms ⚠️
dist/NotFound.960ab92b.js 429.00b +0.00b 5.54s +467.00ms ⚠️
dist/logo.c5bb83f1.png 246.00b +0.00b 4.71s -308.00ms 🚀

AtlasKit Editor 🚨

Timings

Description Time Difference
Cold FAILED -0.00ms
Cached FAILED -0.00ms

Cold Bundles

No bundles found, this is probably a failed build...

Cached Bundles

No bundles found, this is probably a failed build...

Three.js ✅

Timings

Description Time Difference
Cold 7.19s -164.00ms
Cached 295.00ms +1.00ms

Cold Bundles

No bundle changes detected.

Cached Bundles

No bundle changes detected.

Click here to view a detailed benchmark overview.

@AGawrys AGawrys self-requested a review April 11, 2022 17:28
@wbinnssmith wbinnssmith merged commit 2b0b677 into v2 Apr 11, 2022
@mischnic mischnic deleted the wbinnssmith/multiple-ancestors-wrap branch July 5, 2022 11:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants