From 7ab38a5c3c38948729a1afc8db7eca081d9b2433 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Fri, 28 Oct 2022 18:21:22 +0300 Subject: [PATCH] more doc updates... Signed-off-by: Alex A. Naanou --- README.md | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2381d8c..e1c12d3 100644 --- a/README.md +++ b/README.md @@ -2868,6 +2868,10 @@ Handlers can be bound to an eventful method via `.on(, ...)`, unbound via `.off()`, see: [`event.EventHandlerMixin`](#eventeventhandlermixin) for more info. +```dnf +(, ...) +``` + The event `(..)` gets the `(..)` as first argument followed by the arguments passed to `(..)` when called. @@ -2960,22 +2964,39 @@ https://github.com/flynx/object.js#mixin #### `.on(..)` - +Bind a handler to an _event_ or an _eventful_ method. +```dnf +.on(, ) + -> +``` #### `.one(..)` - +Like `.on(..)` but the `` will be called only once. +```dnf +.one(, ) + -> +``` #### `.off(..)` - +Unbind `` from _event_. +```dnf +.off(, ) + -> +``` #### `.trigger(..)` - +Trigger an _event_. +```dnf +.trigger() +.trigger(, ...) + -> +```