I've add a typeahead search. Everithing is working but I've found one issue. I have text in my json for example "Hi, my name is Jason (Mckay) and ..."
When I try to type some words from this string everithin is ok, but when I'll type "(" or ")" I will have an exception: 
Uncaught SyntaxError: Invalid regular expression: /(/: Unterminated group
I was look into typeahead "the Basics" and have the same error: 
 
https://twitter.github.io/typeahead.js/examples/#prefetch
The same when I'll try to input any nubmers first "1", "2" etc...
Here is my default substringMatcher where is the problem: 
var substringMatcher = function(strs) {
      return function findMatches(q, cb) {
        var matches, substringRegex;
        // an array that will be populated with substring matches
        matches = [];
        // regex used to determine if a string contains the substring `q`
        substrRegex = new RegExp(q, 'i');
        // iterate through the pool of strings and for any string that
        // contains the substring 'q', add it to the 'matches' array
        $.each(strs, function(i, str) {
          if (substrRegex.test(str)) {
            matches.push(str);
          }
        });
        cb(matches);
      };
    };
 
    