Post

WGPU is not for replacing html/css. See the rest of the demos of what's being shipped this week: bsky.app/profile/yoav...

YoavCodes@yoav.codes

DOOM is nice, but what if you could use a <electrobun-wgpu> html element right next to your <electrobun-webview> elements and instead of a fully isolated OOPIF you get a super powered GPU surface integrated into the host webview's DOM powered by (bun FFI or native FFI) -> wgpu.

YoavCodes@yoav.codes

Replacing Python as the glue for direct to GPU ML tasks is nice, but what about DOOM 2 ways: - A C implementation (based on DoomGeneric) rendered into a GPU window. - A TypeScript port of DOOM that renders into the same kind of GPU window, using Electrobun’s WGPU APIs from Bun.

YoavCodes@yoav.codes

Games are nice, but Electrobuns new bun -> wgpu unlocks raw gpu compute as well. - lines of code: html: 72, css: 195, browser ts: 318, bun ts: 450. - the ui is using a system webview - the training and inference is done on gpu direct from bun typescript. - dmg is 20.9MB