js source mapping in Chrome

330 views
Skip to first unread message

Robin Burrer

unread,
Nov 11, 2013, 7:16:19 AM11/11/13
to haxe...@googlegroups.com
Hi all,

I would like to debug a js target in Chrome. However Chrome can not load local resources anymore. I was hoping they would change that back at some point. 
So I'm always getting the "Not allowed to load local resource:" error when I try to open a haxe file in Chrome.

Is there a work around for this?

Regards

Robin

Jason O'Neil

unread,
Nov 11, 2013, 7:21:23 AM11/11/13
to haxe...@googlegroups.com
Can you use "nekotools server" to run a local webserver, and test your code from there?

Usually it will listen to "http://localhost:2000", and whatever directory you're in will be the top of the webserver, so you can go to "index.html" from there.

Not sure if that would help in your situation or not...


--
To post to this group haxe...@googlegroups.com
http://groups.google.com/group/haxelang?hl=en
---
You received this message because you are subscribed to the Google Groups "Haxe" group.
For more options, visit https://groups.google.com/groups/opt_out.

Robin Burrer

unread,
Nov 11, 2013, 7:33:30 AM11/11/13
to haxe...@googlegroups.com
Hi Jason,

thanks for your answer. I'm already running a local server and that might actually be the problem. I just tested the app in Chrome using a the file path rather than the localhost and debugging worked.
But since my app needs to have access to webservice running on the local host this is not a solution.....
So I guess its either access to local files or access to remote files.

Robin

Robin Burrer

unread,
Nov 11, 2013, 9:35:07 AM11/11/13
to haxe...@googlegroups.com
I found a fix for my problem. I just start chrome with the "--disable-web-security"  argument. And then I open  my  app form the hard drive (e.g. file:///Applications/XAMPP/xamppfiles/htdocs/myApp/).
Now source mapping + debugging works and my app can also access backend services that are running on the localhost.
Reply all
Reply to author
Forward
0 new messages