i trying write hybrid app android. in app trying load jquery , bunch of other frameworks. javascripts located in assets folder. problem when try load javascript dont see exception, javascript not load.
if give path of invalid file or scheme, see console message , log
<script type="text/javascript" charset="utf-8" src="jquery.js" /> <script type="text/javascript" charset="utf-8" src="js/underscore.js" /> <script type="text/javascript" charset="utf-8" src="js/backbone.js" /> <script type="text/javascript" charset="utf-8" src="js/app.js" /> </head> <body> page loaded... <script> console.log('-----loading-----');
i never see page loaded or ---loading---
but if remove js includes see script being executed. going wrong
<!doctype html> <html> <head> <meta name="viewport" content="width=320; user-scalable=no" /> <meta http-equiv="content-type" content="text/html; charset=utf-8"> <script type="text/javascript" src="some.js"/> <script type="text/javascript" src="some2.js"/> </head> <body> page loaded... <script> console.log('-----loading-----'); </script> </body>
where some.js console.log("!");
and some2.js console.log("2");
i see ! never 2
almost wrong 1 of javascript files. take them out 1 one figure out 1 causing problem, debug script. undefined shouldn't be, there missing bracket or parenthesis, etc.
Comments
Post a Comment