Snapshotting vs Bundling

Snapshotting vs Bundling

TL;DRBunding and snapshotting are two different ways of packing a program for deployment. This post is a somewhat-biased overview of why snapshotting is clearly superior in many respects. I recently wrote up an explanation of Microvium snapshotting, along with this hopefully-helpful animated diagram: In short: the diagram depicts a running Microvium (JavaScript) application that is …

Read More Read More

Microvium

Microvium

Recently, I started working on a bytecode compiler and virtual machine which I’ve currently called Microvium. (For those who have been following me, you’ll know I’ve also been working on a full JavaScript compiler called MetalScript for a while. MetalScript is still in progress and probably will be for some time — it’s not a …

Read More Read More

Node’s require doesn’t always return the same value

Node’s require doesn’t always return the same value

This is just a curious edge case in node.js I came across while looking at creating the module system for microvium. The node.js documentation says: … every call to require(‘foo’) will get exactly the same object returned, if it would resolve to the same file. But this doesn’t seem entirely true. In the following code, a module …

Read More Read More

Can you parse this?
JavaScript Corners

Can you parse this?
JavaScript Corners

What does the following JavaScript mean: Hint: it’s a trick question. The answer depends on the context, as is demonstrated by the following snippet: Within the context of an async function, await is like a keyword, and the thing after await is considered to be an expression. In JavaScript, an expression that starts with forward-slash …

Read More Read More

MetalScript Progress Update – May 2019

MetalScript Progress Update – May 2019

It’s been a while since my last update! Unfortunately, this is because there’s not a lot of observable progress to speak of. But today, here’s another update for those who are interested. I’ll preface this by saying that this update is not particularly interesting. TL;DR: my personal life has got in the way, and MetalScript …

Read More Read More

Hughes List

Hughes List

Inspired by Eric Lippert’s recent post on a data structure called a Hughes list, I thought I’d play around with it by writing my own equivalent in JavaScript. Side note before I get started. For my usual readers who are following the progress of my JavaScript-to-native compiler (MetalScript), I’ll hopefully continue blogging about it soon. …

Read More Read More

TC53 Meeting

TC53 Meeting

Those following my blog will know that I was in Boston last week for ECMA TC53. ECMA is a standards group, and TC53 is the 53rd Technical Committee, being established to produce standards for JavaScript on wearables and other resource-constrained devices. Some of you may already be familiar with TC39, who are the creators of modern JavaScript …

Read More Read More