
Security News
Deno 2.4 Brings Back deno bundle, Improves Dependency Management and Observability
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
create-phaser-game
Advanced tools
A template for creating new Phaser 3 games with Webpack.
yarn create phaser-game [name-of-your-phaser-game]
This will generate a directory with the following contents:
./name-of-your-phaser-game
├── index.html
├── package.json
├── public
│ ├── android-chrome-192x192.png
│ ├── android-chrome-512x512.png
│ ├── favicon-16x16.png
│ ├── favicon-32x32.png
│ ├── favicon.ico
│ └── site.webmanifest
├── src
│ ├── index.css
│ └── index.js
├── webpack.config.js
└── yarn.lock
The src/index.js file is where your Phaser.Game
will be instantiated.
You can import
new scenes from your app into this file like so:
import Phaser from "phaser"
import BootScene from "./scenes/boot"
import WorldScene from "./scenes/world"
document.addEventListener("DOMContentLoaded", () => {
new Phaser.Game({
type: Phaser.AUTO,
scenes: [
BootScene,
WorldScene
]
})
})
A scene in src/scenes might look something like this:
import { Scene } from "phaser"
import tiles from "../images/tiles"
export default class Boot extends Scene {
constructor() {
super({ key: "BootScene", active: true })
}
preload() {
this.load.image("tiles", tiles)
}
}
To run tests:
yarn test
To actually generate an app:
yarn start [name-of-your-phaser-game]
And, for lint checks of the local library:
yarn lint
FAQs
Generate a new Phaser 3 game using Webpack
The npm package create-phaser-game receives a total of 6 weekly downloads. As such, create-phaser-game popularity was classified as not popular.
We found that create-phaser-game demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.4 brings back bundling, improves dependency updates and telemetry, and makes the runtime more practical for real-world JavaScript projects.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.