Skip to content

polyfill-regenerator doesn't support targets #36

@agilgur5

Description

@agilgur5

Issue

Hey there, so I've been trying to add this to TSDX in jaredpalmer/tsdx#795 but ran into an issue: jaredpalmer/tsdx#795 (comment). Long story short, polyfill-regenerator doesn't seem to support targets.

If I'm understanding correctly, this line needs to specify targets per the polyfill-provider docs.

Would be happy to write a PR for this and will look into it more tomorrow. I'm not sure if I should just manually input the data from MDN or if I should use babel-compat-data for transform-regenerator? Any guidance would be appreciated

Context

Per above, was looking to get this to work with TSDX, which would add quite a lot of indirect library users of this.

Concretely, I was adding this to replace the now defunct/unmaintained babel-plugin-async-to-promises (that has some correctness bugs) without the downsides of an impure preset-env useBuiltIns or all-or-nothing transform-runtime.

P.S.

Also just wanted to say really happy to see this set of libraries existing to provide a solution for gaps between preset-env useBuiltIns and transform-runtime, solves a long existing problem!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions