JS has stage 3 decorators proposal
Would it be posible/considered to use ES decorators from rescript?
@defineElement("my-class")
class C extends HTMLElement {
@reactive accessor clicked = false;
}
JS has stage 3 decorators proposal
Would it be posible/considered to use ES decorators from rescript?
@defineElement("my-class")
class C extends HTMLElement {
@reactive accessor clicked = false;
}
Only inside of the %%raw()
block, since ReScript doesn’t support classes directly.
As you can see from the proposal, it’s just a (high-order) function.