.watchers.add
Registers one or more areas to watch with Lampix.
Arguments
...watchers
(Watcher[]
) Comma separated watcher objects or one level deep arrays of watcher objects.
Returns
(Promise<RegisteredWatcher[]>
): A promise that fulfills with a list of RegisteredWatcher
objects, equal in length to the number of watcher objects provided to the function
Example
Notes
If the method receives arrays, it will concatenate them into a single array that will be sent to Lampix. The promise will be resolved with a single array of watchers, in the same order that they were added. For instance:
Last updated
Was this helpful?