board consumed in example

This commit is contained in:
2025-10-16 12:25:52 +01:00
commit 892e85ecf5
38 changed files with 1856 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
import { useGame } from "@vimazing/vim-snake";
import "@vimazing/vim-snake/game.css";
import { useKeyBindings } from "./useKeyBindings";
function App() {
const { containerRef } = useGame(30, 20, useKeyBindings);
return (
<div className="relative mx-auto my-4 w-fit space-y-4">
<h1 className="text-2xl font-bold text-center">VIMazing Snake</h1>
<div ref={containerRef} className="relative" />
</div>
);
}
export default App;