Syntax Lookup

Enter some language construct you want to know more about.
This is the @set decorator.

The @set decorator is used to set a property of an object.

Example

ReScriptJS Output
type window
@val external window: window = "window"
@set external setName: (window, string) => unit = "name"

setName(window, "MyWindow")

References