Create Phaser Game
One of the easiest ways to get started quickly with Phaser is by using our create-phaser-game
app. This is a CLI tool that presents a selection of official project templates and demo games, allowing you to get started quickly with everything set up for you.
You can pick from any of the following templates:
Frameworks | Bundlers |
---|
Vue.js | Vite |
React | Rollup |
Angular | Parcel |
Next.js | Webpack |
SolidJS | ESBuild |
Svelte | Import Map |
Most of these come in both JavaScript and TypeScript versions, and the tool will present this option to you when available.
How to use
To create a new local game template interactively, use one of the following terminal commands:
> npx create @phaserjs/game@latest
> yarn create @phaserjs/game@latest
> pnpm create @phaserjs/game@latest
> bunx create @phaserjs/game@latest
If you would like to pass the project/folder name and skip this step of the tool, you can do so on as a parameter to the create command:
> npx create @phaserjs/game@latest folder-name
The tool will then ask you a series of questions to allow you to configure your game template.
Once installed you can modify the template settings and check its own README.md
file for further instructions.
Created by Phaser Studio Inc.