Closed grayflow closed 6 years ago
I'd had the same thought that it would be interesting to see Curveball running on top of Deno - partly just because I learned about them both at roughly the same time. It looks like they're getting pretty close to a stable release over there. Would it be a good time to revisit this issue?
It's definitely possible, and not too difficult already to do this.
There's some dependencies on node.js specific stuff, but these implementation details are all hidden behind things that are overrideable.
Currently there are NodeRequest and NodeResponse classes. Both of these inherit from Request/Response. A different non-node implementation can just subclass these 2 classes again, and it will just work.
There is some node-specific stuff in for example Application.listen(), but this is just a convenient shortcut and doesn't need to be used.
So for now I will close this as 'invalid'. Once deno is out, and it has good HTTP apis, it would be good to revisit how we can make this easier, or just ship this stuff out of the box.