giraffe icon indicating copy to clipboard operation
giraffe copied to clipboard

Issue with Tree Shaking

Open counterbeing opened this issue 4 years ago • 1 comments

I'm having an issue with tree shaking, and I'm not sure why. I'm not certain this is a bug, but it may be. I'm using Create React App, and have a very large bundle. I've simplified the problem by just importing two modules, and still i have a bloated bundle.

Here's my only import line for giraffe:

import { newTable, Table } from '@influxdata/giraffe';

And here's how the bundle looks:

image

I took a peek into the code, and it seems as though they're es6 exports that should allow for tree shaking. Am I missing something?

Thanks!

counterbeing avatar Jan 28 '21 01:01 counterbeing

Due to architectural design, we cannot reduce package size significantly.

kristinarobinson avatar Mar 12 '21 20:03 kristinarobinson