Function

addListener (obj, eventName, target, method, once) public

Module: @ember/object
import { addListener } from '@ember/object/events';
obj
eventName
String
target
Object|Function
A target object or a function
method
Function|String
A function or the name of a function to be called on `target`
once
Boolean
A flag whether a function should only be called once

Add an event listener

© 2020 Yehuda Katz, Tom Dale and Ember.js contributors
Licensed under the MIT License.
https://api.emberjs.com/ember/3.25/functions/@ember%2Fobject%2Fevents/addListener