Function

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