[COMPASS-5535] Make browser-repl bundle tree-shakable by Compass Created: 23/Feb/22  Updated: 27/Oct/23  Resolved: 22/Jun/23

Status: Closed
Project: Compass
Component/s: Browser Module, Build, Tech debt
Affects Version/s: None
Fix Version/s: No version

Type: Task Priority: Major - P3
Reporter: Rhys Howell Assignee: Unassigned
Resolution: Gone away Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to COMPASS-6241 Code Editors: Add dark theme support ... Closed
is related to COMPASS-5422 Update leafygreen in browser-repl / f... Closed
is related to COMPASS-6205 Refactor browser-repl to use compass-... Closed
Documentation Changes: Not Needed

 Description   

Because browser-repl is bundled with webpack it's dependencies are always included in the distribution and can't be tree shaken by the bundling tools of Compass. This means that even if we completely align leafygreen dependencies in Compass, we are still running into the risk of having multiple versions of emotion running on one page due to browser-repl distribution type and the outdated version which leads to the potential visual issues in the application.

To solve that we need to find a way to not include dependencies shared with Compass in the bundle (we can either make them external / peer deps or provide special exports key similar to how Compass currently resolves monorepo packages from source using exports.webpack package.json property)



 Comments   
Comment by Sergey Petushkov [ 22/Jun/23 ]

browser-repl is not bundled by webpack anymore

Generated at Wed Feb 07 22:39:55 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.