cferdinandi / tabby

Lightweight, accessible vanilla JS toggle tabs.
MIT License
599 stars 73 forks source link

Unexpected token ( - SyntaxError #1

Closed tnguyen14 closed 11 years ago

tnguyen14 commented 11 years ago

I got the following error while using tabby.

Uncaught SyntaxError: Unexpected token ( 

I am including tabby using require.js with the following config:

  shim: {
    tabby: ['jquery']
  }
tnguyen14 commented 11 years ago

Also, this error is reported at tabby.js:16 , where:

  var this = $(this);
cferdinandi commented 11 years ago

@tnguyen14 - This appears to be an issue with require.js and/or the way you've configured it, rather than with Tabby.

When included in your HTML document like this, Tabby does not generate any errors:

 <script src="js/jquery.js"></script>
 <script src="js/tabby.js"></script>

You might start troubleshooting here: http://stackoverflow.com/questions/10929435/require-js-and-js-test-driver-unexpected-token