Skip to content

Instantly share code, notes, and snippets.

@brainlid
Forked from joachimhs/gist:3529609
Last active January 3, 2016 10:08
Show Gist options
  • Save brainlid/8447027 to your computer and use it in GitHub Desktop.
Save brainlid/8447027 to your computer and use it in GitHub Desktop.
init: ->
@_super()
view = this
resizeHandler = ->
view.rerender()
@.set('resizeHandler', resizeHandler);
$(window).bind('resize', @get('resizeHandler'))
willDestroy: ->
$(window).unbind('resize', @get('resizeHandler'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment