Page MenuHomePhabricator

[lib] Remove url-parse-lax from Webpack bundles
ClosedPublic

Authored by ashoat on Feb 12 2023, 6:44 PM.
Tags
None
Referenced Files
F3486139: D6698.diff
Wed, Dec 18, 3:18 AM
Unknown Object (File)
Fri, Dec 6, 7:01 AM
Unknown Object (File)
Wed, Dec 4, 5:13 PM
Unknown Object (File)
Tue, Dec 3, 1:16 PM
Unknown Object (File)
Tue, Dec 3, 11:27 AM
Unknown Object (File)
Fri, Nov 22, 11:27 AM
Unknown Object (File)
Nov 11 2024, 4:44 AM
Unknown Object (File)
Nov 11 2024, 4:42 AM
Subscribers

Details

Summary

By including this in lib/utils/url-utils.js, we end up including it in the Webpack bundles for web and landing. This bloats bundle size, and is also a problem because url-parse-lax only works in the Node.js environment and Webpack 5 prints a warning about that.

Our only usage of the normalizeURL function is from Markdown linking code in native, so this diff moves that usage to native so we don't include normalizeURL or url-parse-lax in our Webpack bundles.

Depends on D6697

Test Plan

Confirm native app still runs, bundle still generates, and Markdown links still navigate to the linked URL

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage