-module(react_gleam@attribute). -compile(no_auto_import). -export([attribute/2, property/2, event/2]). -export_type([attribute/1]). -opaque attribute(ENI) :: {attribute, binary(), binary()} | {property, binary(), gleam@dynamic:dynamic()} | {event, binary(), fun((gleam@dynamic:dynamic(), fun((ENI) -> nil)) -> nil)}. -spec attribute(binary(), binary()) -> attribute(any()). attribute(Name, Value) -> {attribute, Name, Value}. -spec property(binary(), gleam@dynamic:dynamic()) -> attribute(any()). property(Name, Value) -> {property, Name, Value}. -spec event(binary(), fun((gleam@dynamic:dynamic(), fun((ENN) -> nil)) -> nil)) -> attribute(ENN). event(Name, Handler) -> {event, Name, Handler}.