CodePen

HTML

            
              <input id="tag-search">

<p id="results"></p>
            
          
!

CSS

            
              
            
          
!
? ?
? ?
Must be a valid URL.
+ add another resource
via CSS Lint

JS

            
              (function() {
    var timeout;
    $('#tag-search').keyup( function() {
        var elem = $(this);
        if (elem.val().length >= 2) {
            clearTimeout(timeout);
            timeout = setTimeout(function() { 
              $('#results').text("Search for: " + elem.val());
              //$.ajax({ // ajax stuff
              //     'success': function(data){ /*show result*/ }
              // });     
            }, 500); // <-- throttle                                      
        } else if (string.length <= 1) { /*show original content*/ }
    });
}());
            
          
!
Must be a valid URL.
+ add another resource
via JS Hint
Loading ..................