← Notes

Notes

Draft · not listed

A small lab of things a browser can do

A scratch notebook. Each cell below is a small experiment: open one, poke at it, move on. They run inside this page — no installs, nothing to download (except cell 06, which is opt-in). The goal isn't to be clever; it's to remember how much you can get away with from a single static HTML file.

Lab · scratchpad/06 06 cells
[ 01 ]

Geometry, lit and turning

live

A torus knot with two soft point-lights, rotating on its own. Drag inside the viewport to orbit the camera. ~80 lines of Three.js, no shader code.

three.js r160 · webgldrag · scroll-zoom off

[ 02 ]

Particles that want to be near you

live

A few hundred particles, each with a tiny attractor pointed at the cursor and a drag term. Move the mouse over the viewport. Touch works too.

2d canvas · 600 particlesmove cursor · touch ok

[ 03 ]

Sound, synthesized on the fly

idle

Click a pad to hold a sine partial; the right side draws the live time-domain signal. The browser is a synth — Web Audio gives you oscillators, gain, FFTs, and analyser nodes for free.

web audio · sine oscillatorsclick pads to play

[ 04 ]

A tiny scratch buffer for JavaScript

live

Edit the code on the left, hit Run, and see whatever you logged or returned on the right. Sandboxed in a Function constructor — no eval against this page's globals.


          
⌘/Ctrl + Enter

js · sandboxed function ctorcmd+enter to run

[ 05 ]

Typesetting math, no PDF needed

live

KaTeX renders LaTeX in milliseconds. Move the slider to change the order of the Taylor polynomial and watch the expression rebuild itself.

order n = 4

katex 0.16 · client-side typesettingslide n

[ 06 ]

Python, inside the tab

not loaded · ~12 MB

Pyodide compiles CPython to WebAssembly. The runtime is heavy (~12 MB on first load, cached afterwards), so you opt in. After it's ready you have NumPy and most of the standard library, no server, no install.

idle

        

pyodide 0.26 · cpython on wasmnumpy loaded on demand

— end of notebook —

What the page itself isn’t doing

Every cell above is self-contained inside its viewport. There’s no build step, no framework, no SPA router. The whole thing is a Markdown file that ships HTML to a Jekyll layout and pulls in a few small scripts on demand. The browser does the rest.