Skip to content

Instantly share code, notes, and snippets.

@VladimirPal
Last active August 29, 2015 14:16
Show Gist options
  • Save VladimirPal/d39f759156b8effbd12f to your computer and use it in GitHub Desktop.
Save VladimirPal/d39f759156b8effbd12f to your computer and use it in GitHub Desktop.
Delay search input
delay_search_input: (ev) ->
ev.preventDefault()
clearTimeout(@delay_id)
@delay_id = _.delay () =>
value = $(ev.target).val()
,1500
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment