JSFoo Chennai 2020

JSFoo Chennai 2020

On component architecture, performance, security for front-end, and emerging trends

Ankur Sethi

Ankur Sethi

@s3thi

WebAssembly Everywhere: How WebAssembly is Becoming a Universal Runtime for Untrusted Code

Submitted Feb 27, 2020

WebAssembly started out as a bytecode format to allow code written in low-level languages to run inside web browsers. However, it is slowly breaking out of the browser to become the tool of choice for any computing task that involves running untrusted code in a safe, portable, and performant way. From serverless computing to desktop applications to blockchain, WebAssembly is finding applications in a variety of different environments.

How did get here? What makes it suited to these wildly different application domains? Most importantly, why should you care? Find out in this session.

Outline

The Why, How, and What of WebAssembly

This section will include a short history of WebAssembly, from the dawn of compile-to-JS languages to the state of WebAssembly runtimes today. We will look at code samples and demos to show what WebAssembly code looks like, and understand how it’s actually compiled and executed by a runtime. At some point, we’ll cross our fingers and make a blood sacrifice to the demo gods.

WebAssembly in the Browser

The advertised use case for WebAssembly in the browser is portability, and the ability to achieve performance that has so far been impossible with JavaScript. How does this work out in practice? In this section, we talk about organizations who have used WebAssembly to enable features that were hard or impossible to build with plain JavaScript. Since no tool is perfect, we will also talk about cases where WebAssembly is not the right tool for the job.

WebAssembly on Desktop and Servers

WebAssembly enables true polyglot development, where you can write your code in a low-level language like Rust and call it from JavaScript, Python, Ruby, or any other programming language that supports loading WebAssembly modules. In this section, we look into the tools that allow us to do this, including wasmtime and the upcoming WASI standard.

WebAssembly on Serverless

WebAssembly enables lightweight sandboxing of the kind that’s impossible with virtual machines or containers, which has led to CloudFlare and Fastly investing a lot of effort (and $$$) into the technology. In this section, we look at how WebAssembly is changing the face of serverless development and edge computing, and what the future looks like for running it on servers.

Requirements

Some experience building frontend applications, and familiarity with the concept of serverless development.

Speaker bio

Ankur Sethi is an independent front-end developer currently building open-source applications with Rust. He has spent the better part of the last decade building webapps for clients as diverse as Aditya Birla, Insider.in, and Pratham Books. He likes cats, Urdu poetry, and chai.

Comments

{{ gettext('Login to leave a comment') }}

{{ gettext('Post a comment…') }}
{{ gettext('New comment') }}
{{ formTitle }}

{{ errorMsg }}

{{ gettext('No comments posted yet') }}

Hosted by

JSFoo is a forum for discussing UI engineering; fullstack development; web applications engineering, performance, security and design; accessibility; and latest developments in #JavaScript. Follow JSFoo on Twitter more