Use the language of your choice with Pages Functions via WebAssembly
Cloudflare's developer platform has introduced WebAssembly (Wasm) support for their Pages Functions projects, enabling developers to build server-side applications with languages other than JavaScript. Wasm is a low-level language designed to run on the web and provides programming languages like C/C++, C#, or Rust with a compilation target. Using WebAssembly in Cloudflare's Pages Functions works similarly to how it does in Workers, allowing developers to import compiled binary .wasm files and use their features within their functions code. This update also supports two other module types: text and binary, which can be imported as strings or data blobs, respectively. To demonstrate the new feature's potential, Cloudflare has developed a small demo app that calculates distances between two points on Earth using Rust-generated WebAssembly, showcasing how developers can build powerful applications with this new support.
Company
Cloudflare
Date published
March 24, 2023
Author(s)
Carmen Popoviciu
Word count
1032
Language
English
Hacker News points
3