Created
October 13, 2014 23:20
-
-
Save etozzato/85da5cb66ab935d06ebf to your computer and use it in GitHub Desktop.
Window Resize
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// in the component's didInsertElement | |
$(window).on('resize', function() { | |
return Em.run.debounce(that, 'resizeWindow', 250); | |
}); | |
// in the route's willTransition | |
$(window).off('resize'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment