JavaScript React Basics (retired) First Steps in React Our First Application

Luca Spezzano
Luca Spezzano
10,417 Points

Working on Firefox but not on Chrome why?

I just downloaded the work space, when i open the index file on Firefox i see Hello but on Chrome i just see Loading, somebody can help? Thanks!

2 Answers

Luca Spezzano
Luca Spezzano
10,417 Points

That's the answer: http://stackoverflow.com/questions/20041656/xmlhttprequest-cannot-load-file-cross-origin-requests-are-only-supported-for-ht

you can run this command in the folder: python -m SimpleHTTPServer 8000

And it will run a local server and it will work!

Sanjeev Veloo
Sanjeev Veloo
4,713 Points

You can start a simple HTTP server to get around this. I know that this link shows you how to do it for a Mac using terminal. Easy As.

http://www.linuxjournal.com/content/tech-tip-really-simple-http-server-python