Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting className to custom tag fails #134

Open
unclechu opened this issue Feb 15, 2018 · 3 comments
Open

Setting className to custom tag fails #134

unclechu opened this issue Feb 15, 2018 · 3 comments

Comments

@unclechu
Copy link

purescript-react is v5.1.0

When I declare my own tag name by this command:

createElementTagName "my-own-tag-name" [className "container"]

And then when its rendered I got this tag in DOM tree but without class attribute and I see this warning in log:

Warning: Invalid attribute name: `0`
warning.js:33
@unclechu
Copy link
Author

Maybe I misunderstood something? I just used

mkDOM (IsDynamic false) "my-own-tag-name" [class "container"]

instead and it works.

@unclechu
Copy link
Author

I think I get it, createElementTagName is free to put anything as props, so I put array when I supposed to put a record, am I right?

@ethul
Copy link
Contributor

ethul commented Feb 24, 2018

Yes, you're correct. The props would have to be a record in this case.

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

No branches or pull requests

2 participants