squeaky-pl / japronto

Screaming-fast Python 3.5+ HTTP toolkit integrated with pipelining HTTP server based on uvloop and picohttpparser.
MIT License
8.61k stars 581 forks source link

Can I allow CORS? #31

Closed hueypark closed 7 years ago

hueypark commented 7 years ago

If not, where can I add it?

aphillipo commented 7 years ago

CORS is just a header or a meta tag. It's relatively simple to add headers to the response object I imagine.

aphillipo commented 7 years ago

Okay so when returning a request.Response(headers={'Access-Control-Allow-Origin': 'some uri'}) should be a starting point for you...

hueypark commented 7 years ago

Thank you