You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
All of d3 gets bundled with @hackoregon/ui-maps, in places where only some of d3 is needed. All places where import * as d3 from "d3"; is used should be replaced with imports of the needed functions from the smaller d3 modules such as d3-geo.
Steps to reproduce
Use create-react-app to start a new project, yarn add @hackoregon/ui-maps, and use a component like PolygonPreview. Then build, and inspect your bundle using source-map-explorer to see that all of d3 is there.
Screenshot of source-map-explorer showing d3 bundles
Expected result
Should only import needed functions from d3-geo
Actual result
Imported all of d3
The text was updated successfully, but these errors were encountered:
Description
All of d3 gets bundled with
@hackoregon/ui-maps
, in places where only some of d3 is needed. All places whereimport * as d3 from "d3";
is used should be replaced with imports of the needed functions from the smaller d3 modules such asd3-geo
.Steps to reproduce
Use create-react-app to start a new project,
yarn add @hackoregon/ui-maps
, and use a component likePolygonPreview
. Then build, and inspect your bundle usingsource-map-explorer
to see that all ofd3
is there.Screenshot of source-map-explorer showing d3 bundles
Expected result
Should only import needed functions from
d3-geo
Actual result
Imported all of d3
The text was updated successfully, but these errors were encountered: