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
can't setting attribute in root element #289
Comments
+1 to support setting attribute on root el will be useful for styling. |
+1 |
This should definitely be supported. Also planning adding some sort of attribute validation to the root attributes. |
Any workaround for this? <input />
<script type="riot/tag">
<input onchange={this.changeEvent}>
this.changeEvent = function() {
console.log(this);
}
</input>
</script> I have to setup two-way binding with a library and this issue is preventing me from doing so. I think |
Try following: <custom-input></custom-input>
<script type="riot/tag">
<custom-input>
<input onchange={ changeEvent }>
changeEvent() {
console.log(this);
}
</custom-input>
</script> |
so @tipiirai, according to your last comment it seems riot will support attributes on the root tag but not events. Is that correct? Do you expect this to change in the future? |
I think root attributes should be fully supported, but cannot give you any ETA |
the root element in tag files does not support attribute setting:
The text was updated successfully, but these errors were encountered: