@tinyactors/scxmljs
    Preparing search index...

    Function bind

    Everything both entry points share. Import from @tinyactors/scxmljs (sandboxed) or @tinyactors/scxmljs/trusted instead of this file.

    • Declarative sends, by event delegation on root:

      • data-scxml-send="name": send name. Default trigger: click; for a <form>, submit (default prevented; data = the form's fields); for <input>/<select>/<textarea>, change (data = { name, value }, plus checked for checkboxes and radios).
      • A submit button with data-scxml-send inside a form names the event its submission sends (data = the form's fields): one form, several actions.
      • data-scxml-on="dblclick keydown": override the trigger(s).
      • data-scxml-data='{"json": true}': static data, merged over the dynamic data (invalid JSON: nothing is sent).
      • data-scxml-session="<sessionId>" on the element or an ancestor: only that session reacts. Unmarked elements inside root go to every session bound to root.

      Parameters

      Returns () => void