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

Is there a default implementation for method `OPTIONS`? #34

Closed hueypark closed 5 years ago

hueypark commented 7 years ago

If you do not have a default implementation, you should implement OPTIONS every time you use CORS withDELETE Any plan?

squeaky-pl commented 7 years ago

there are plans for middleware-like funcionality that will let you do it nicely but I cannot promise any date.

you can put your CORS logic into a function decorator for now and decorate all the views with a decodator.