Skip to content

[webpack] is tree shaking working? #9251

@Roman991

Description

@Roman991

For both:

Chart.register(
  Title,
  Tooltip,
  Filler,
  Legend,
  BarController,
  LineElement,
  LinearScale,
  BarElement,
  TimeScale
);

and this (all imports)

Chart.register(
  ArcElement,
  LineElement,
  BarElement,
  PointElement,
  BarController,
  BubbleController,
  DoughnutController,
  LineController,
  PieController,
  PolarAreaController,
  RadarController,
  ScatterController,
  CategoryScale,
  LinearScale,
  LogarithmicScale,
  RadialLinearScale,
  TimeScale,
  TimeSeriesScale,
  Decimation,
  Filler,
  Legend,
  Title,
  Tooltip
);

the final bundled chunks both have the same weight: 526,66KB
(obviously I only imported the necessary components)
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions