Skip to content

Proxy code generated by npx typewriter breaks webpack tree shaking #330

@dhruv343

Description

@dhruv343

The proxy code generated for Segment Typewriter doesn't allow webpack to properly treeshake the file.Even if one I import just a single function as a named import from the file ,the entire file gets included in the chunk increasing bundle size for my application's initial chunks
The proxy code acts as a sideEffect here for webpack

Is there a way we can prevent this code from being generated?

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions