Getting Started#

Run the following command to create a new GameKit project:

gamekit init <path-to-project-directory>
gamekit init .

You'll be prompted for the project name, description, version, author and package manager.

Install Dependencies#

Next, install the project dependencies. The command varies based on your package manager:

yarn install
npm install

Run The Dev Server#

Start the dev server using the following command. The dev server watches your source files and restarts when changes are detected, providing a rapid development experience.

yarn dev
npm run dev

Project Directory#

A typical GameKit project has the directory structure shown in the image below. The table below describes the function of each item.

Path Description
gamekit/ Auto-generated directory used by the engine as a workspace
src/ Contains all source code and assets for your game
src/assets/ Contains all asset files used in your game
src/public/ Contains files to include in the final public directory as-is
src/main.tsx The entry point into your game
src/main.css The main CSS file of your game. You can use it to customize UI elements.
.env Holds environment variables your game might need at runtime
.gitignore Git ignore file, indicating files that should be ignored from version control
.prettier Configuration file for the Prettier code formatter
eslint.config.js Configuration file for the ESlint code linter
gamekit.config.ts Configuration file for GameKit
package.json Configuration file for Node/NPM
tsconfig.json Configuration file for the Typescript compiler

Next Steps#

In the next guide, we'll explore the available project configuration options.