1
votes

Since today I am getting an error as follows:

Uncaught TypeError: X[g].exec is not a function fb tokenize

This is the stack trace:

Uncaught TypeError: X[g].exec is not a function fb.tokenize @ jquery.min.js:2 fb.compile @ jquery.min.js:2 fb.select @ jquery.min.js:2 fb @ jquery.min.js:2 m.event.handlers @ jquery.min.js:3 m.event.dispatch @ jquery.min.js:3 r.handle @ jquery.min.js:3

The project is an Angularjs app built in an .NET MVC Area. Dependencies are:

Edit

Seems to be a problem with Bootstrap.js file, where an alert is supposed to be dismissed but not found. JQuery Sizzle can't find "[alert-dismiss]". The fb is Sizzle in minified version of JQuery.

3
I recommend finding out more information about what exactly is broken here. One way do approach this would be to not use minified versions of the code involved in your development/testing setup, and include debug symbols wherever appropriate. - derabbink
i think it will work for you.. enter link description here - Sultan Belai

3 Answers

16
votes

I had the same X[g].exec is not a function error and in my case it was because i defined a Object.prototype.count function.

4
votes

I found the culprit.

Seems there was a disturbance in the force with the combination of bootstrap.js and the angular bootstrap ui library. After removing the unnecessary bootstrap.js all was well.

0
votes

To solve that, add the following to your code:

Function.prototype.exec = Object.prototype.exec = function() {return null};