Skip to content

Companion repo with examples of Same Origin Policy work arounds: proxy server, JSONP, and CORS

License

Notifications You must be signed in to change notification settings

valgaze/same_origin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CORS

See companion blogpost here: https://medium.com/@valgaze/utility-post-cors-json-p-proxy-servers-and-the-same-origin-policy-7233dec2d26c#.wcmnhsnyo

Proxy server example

$ npm run proxy

Then in a browser access: http://localhost:3000/proxy/4


JSONP example

$ npm run jsonp

Then in a browser access: http://localhost:3000/


CORS example

You need to turn on two servers for this example:

Turn on API server

$ npm run cors_server

Turn on Frontend

$ npm run cors_frontend

Then in a browser access: http://localhost:3001/


About

Companion repo with examples of Same Origin Policy work arounds: proxy server, JSONP, and CORS

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published