title: Bootstrap 3 typeahead.js, use similar functions from Bootstrap 2
body: <p>I have updated Bootstrap 2 to Bootstrap 3, and the biggest problem is that typeahead has been removed, and it's recommended the use of typeahead.js. So I installed it, and the easy uses of typeahead work without problems, but I also use other functions like:</p>
  
  <pre><code> $('#my_field').typeahead({
       source : [list_of_items],
       matcher: function(item) {
           foo();
           return item;
       },
       updater : function(item) {
           foo2();
           return item;
       },
       closed: function(item) {
         ...
       },
       autocompleted: function(item) {
         ...
       }
   });
  </code></pre>
  
  <p>How can I implement similar functions using typeahead.js?</p>
  
  <p>Under <a href="https://github.com/twitter/typeahead.js" rel="nofollow">https://github.com/twitter/typeahead.js</a> are some functions like </p>
  
  <pre><code>typeahead:initialized, typeahead:opened, typeahead:closed
  </code></pre>
  
  <p>but there are no examples on how to use them</p>