Browsersaurus Rex
Building a Game, Inside a Browser Extension
A Chrome extension that turns the web into a creature collection game. Every website generates a unique, procedurally generated tyrannosaurus with autonomous AI. It's Pokémon meets Tamagotchi, running entirely within the sandbox of a browser extension.
The Technical Challenge, Engineering for the Sandbox
Context Orchestration: Built a PixiJS based engine spanning four isolated contexts (Service Worker, Content Script, Popup, and Hub) using typed message passing for state synchronisation.
Bypassing Manifest V3: Navigated strict CSP, dynamic asset bans, and Chrome's 128MB maximum extension size limit by ******** ********* ***** ** *** ****** ****** and ******* ******* ********* ****** ** ******** .
Deterministic Generation: ****** ***** *** ****** ** ************* ******* ******* to seed appearance, stats, and rarity. Same URL = Same Rex, for every user, forever.
The Tech Stack
Graphics: React, TypeScript, and PixiJS v7 with Spine 2D for skeletal animation and smooth state transitions. I had to to bend PixiJS to handle dynamic runtime assets by ************ *** ******** ******* ***** *** ****** ******* .
Performance: Custom animation queue system and ticker management to pause game loops when tabs are hidden, ensuring zero impact on host page performance.
Persistence: * ****** ******* ***** ******** **** ******* *** **** **** within the background worker.
Why It Matters
Browsersaurus Rex is my a playground for exploring the edges of browser sandbox constraints. It's about making high fidelity graphics and complex procedural systems feel native and magical in the most locked down environment on the web.