@ujjwalvivek/journey-engine
v1.1.2
Published
Journey Engine: A custom 2D game engine built with Rust and wGPU
Maintainers
Readme
Journey Engine: WASM Distribution README (@ujjwalvivek/journey-engine)
WebAssembly build of Journey, a custom 2D Metroidvania game engine built from scratch in Rust. By hosting the compiled .wasm binaries on the global CDN, the engine's Git repository remains 100% clean of binary bloat while allowing frontend wrappers to time-travel between engine versions dynamically.
You can read the full technical breakdown of this engine's development at ujjwalvivek.com.
Tech Stack
- Core Engine: Rust
- Compilation Target: WebAssembly (
wasm32-unknown-unknown) - Web Integration:
wasm-bindgen,web-sys - Frontend Wrapper: TypeScript, Vite
How to Load This Package
If you want to run this specific historical version of the engine in a web project without installing local binaries, you can fetch it dynamically at runtime using an ES module import from the jsDelivr CDN.
async function journeyEngine() {
const version = "${version}"; //? This should match the version in package.json
const cdnUrl = `https://cdn.jsdelivr.net/npm/@ujjwalvivek/journey-engine@${version}/game.js`;
try {
//? Fetch and initialize the compiled Rust engine directly from the CDN
const module = await import(/* @vite-ignore */ cdnUrl);
const init = module.default;
await init();
console.log(`Journey Engine v${version} booted successfully!`);
} catch (error) {
console.error("Failed to load Engine from CDN:", error);
}
}
journeyEngine();License
MIT License. See LICENSE for details.
