com-lihaoyi / cask

Cask: a Scala HTTP micro-framework. Cask makes it easy to set up a website, backend server, or REST API using Scala
https://com-lihaoyi.github.io/cask/
Other
525 stars 55 forks source link

Any thoughts for Cloudflare Workers? #131

Closed windymelt closed 1 month ago

windymelt commented 2 months ago

Cloudflare Workers is small but nice platform to build cloud API: if we export default function, Cloudflare automatically execute it on each request.

As we know, Cask is also small but nice platform to build API in Scala. It goes along simple Scala manner, easy to use.

My idea is: Providing Cloudflare Worker module in Cask makes great synergy in Scala ecosystem. If we turn Cask code into one function that recognize request and return result, we can run Cask in Cloudflare ecosystem immidiately (Just like Hono. We can compete against it).

Could you tell me your opinion about bridging Cask and CF Workers?

lihaoyi commented 1 month ago

Cask doesn't run on Javascript, so it seems like it won't work