raylib-wasm
Version:
Make raylib games in JS for the web
15 lines (13 loc) • 331 B
HTML
<script type="module" src="raylib/raylib.js"></script>
<raylib-game>
const InitGame = async () => {
InitWindow(800, 450)
}
const UpdateGame = (ts) => {
BeginDrawing()
ClearBackground(RAYWHITE)
DrawText("Congrats! You created your first window!", 190, 200, 20, LIGHTGRAY);
DrawFPS(10, 10)
EndDrawing()
}
</raylib-game>