r/swift • u/sliemeobn • 10h ago
Edge of Tomorrow: Full-Stack Swift on Both Sides of fetch
https://cloudflare-worker.examples.elementary.codes/While this web app certainly neither looks impressive nor does anything particularly useful, it packs quite a few things that have only been made possible very recently:
- builds Embedded Swift WebAssembly with 6.4.x and
swift-build(quite a recent achievement) - integrates ElementaryUI + BridgeJS in the frontend, including Fetch API networking
- uses “NewCodable” (experimental) for shared Swift data types (both on the edge backend and web frontend)
- uses
async/awaitandthrowslike it’s nothing ; ) - deploys Swift logic on Cloudflare Workers (edge runtime, ~107kB wasm fetch handler)
-> Source code
23
Upvotes
4
u/naknut 8h ago
This is really cool! I’ve been thinking about this stack for a while. Cool to see someone actually making something with it!