Skip to content

Thoughts on building esm at python packaging time #71

Description

@paddymul

What are your thoughts on a pattern like this?

In the future, when I care about bundle sizes of my widget, I would prefer not to ship sucrase in the bundled JS. My _esm cproperties are very small, essentially shims between my component library and ipyreact. What would it look like if there was no sucrase shipped with js bundle. (I'm not worried about the time it takes to execute sucrase, this should be minimal.

What if the _esm blocks were hashed and compiled in a step. Then there was a shipped dictionary from _esm_hash to compiled js. The frontend code references this dictionary in production mode, and the 1mb sucrase dependency doesn't ship.

This is a pretty advanced optimization that I don't think I'll get to for a while, if ever. but curious on your thoughts

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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