Skip to content

make it possible to use harmony transforms in the browser with script tags #1420

@zpao

Description

@zpao

We already have the option enabled in the browser transform, and we export a function there that takes an option (for use with react-rails, et al). But we didn't make it possible to pass options from your <script type="text/jsx"> blocks. Let's do it.

Since there are no JS data types in html, let's just do an JSON.stringifyed data-options attribute.

There's only the single option right now, so <script type="text/jsx" data-options="{\"harmony\": true}" is all we need to support. Other options can be added easily if they come up.

Metadata

Metadata

Assignees

No one assigned

    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