KyleAMathews / element-resize-event

Library to make it easy to listen for element resize events
http://kyleamathews.github.io/element-resize-event/
MIT License
175 stars 44 forks source link

Assign `this` to window in `requestFrame` and `cancelFrame` #18

Closed eligolding closed 7 years ago

eligolding commented 7 years ago

Fixes #17

In #14 the requestFrame and cancelFrame functions were moved into the global scope, so window is now undefined when requiring in node. Previously they were created in the export function which uses a reference to this as window. Doing the same thing in requestFrame and cancelFrame fixes this problem.

KyleAMathews commented 7 years ago

Thanks!

eligolding commented 7 years ago

Wow that was fast! Thank you!

KyleAMathews commented 7 years ago

It takes like 30 seconds to do a release :-)

On Wed, Mar 22, 2017, 8:30 AM Eli Golding notifications@github.com wrote:

Wow that was fast! Thank you!

— You are receiving this because you modified the open/close state.

Reply to this email directly, view it on GitHub https://github.com/KyleAMathews/element-resize-event/pull/18#issuecomment-288436402, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEVh2-a4VLJJi87sMch36B3K3ZRvFKrks5roT6BgaJpZM4MlXjF .