Skip to content

Add attributes to "element" #5

Open
@felixSchl

Description

@felixSchl

Is it possible to add attributes to elements created via element?

-- myLink's render function: `renderIn DOM.a' $ text "click me"`
let myLink = React.createElement fooClass {} []
    myLink' = element myLink
 in renderIn DOM.div' d
      myLink' !. "navbar-item"

This give me a <a>click me</a>, where I expected a <a class="navbar-item">click me</a>. Is this supposed to work, and is my approach right?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions