Created
          March 25, 2018 06:39 
        
      - 
      
- 
        Save ben-rogerson/51d28640eabb40881aadb1772067efd9 to your computer and use it in GitHub Desktop. 
    Cheap Ass Debouncing
  
        
  
    
      This file contains hidden or 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
    
  
  
    
  | let counter = 0 | |
| const isTimeToUpdate = (updateRate = 10) => counter++ % updateRate === 0 | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment