Commit 3d8982f8 authored by Eduardo's avatar Eduardo

Apply suggestions from code review

Co-authored-by: 's avatarRobert Knight <robertknight@gmail.com>
parent 2eba3b24
......@@ -16,7 +16,7 @@ export class ListenerCollection {
}
/**
* Adds a listener and returns a listenerId
* Add a listener and return an ID that can be used to remove it later
*
* @param {Listener['eventTarget']} eventTarget
* @param {Listener['eventType']} eventType
......@@ -31,7 +31,8 @@ export class ListenerCollection {
}
/**
* Removes a listener using a listenerId
* Remove a listener using a listenerId
*
* @param {Symbol} listenerId
*/
remove(listenerId) {
......
......@@ -22,7 +22,7 @@ describe('ListenerCollection', () => {
});
describe('#remove', () => {
it('unregisters some event listeners', () => {
it('unregisters the specified listener', () => {
const listener1 = sinon.stub();
const listener2 = sinon.stub();
listeners.add(window, 'resize', listener1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment