Skip to content

Commit

Permalink
docs: detail delimiters for actions
Browse files Browse the repository at this point in the history
  • Loading branch information
francisfuzz committed Jun 28, 2024
1 parent 865a15c commit 43a6b7f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/_guide/actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ class HelloWorldElement extends HTMLElement {
The actions syntax follows a pattern of `event:controller#method`.

- `event` must be the name of a [_DOM Event_](https://developer.mozilla.org/en-US/docs/Web/Events), e.g. `click`.
- `:` is the required delimiter between the `event` and `controller`.
- `controller` must be the name of a controller ascendant to the element.
- `#` is the required delimieter between the `controller` and `method`.
- `method` (optional) must be a _public_ _method_ attached to a controller's prototype. Static methods will not work.

If method is not supplied, it will default to `handleEvent`.
Expand Down

0 comments on commit 43a6b7f

Please sign in to comment.