Skip to content

Conversation

@justin-calleja
Copy link

@justin-calleja justin-calleja commented Sep 22, 2025

Ports it to using app router. Can be kept in a separate branch and linked to in README.md for example.

Cannot target any other branch than main from here though.


Note

Migrates to Next.js App Router with client-only Phaser setup, adds integration docs, updates TS config, and bumps Phaser to 3.90.0.

  • App Router Migration:
    • Add src/app/layout.tsx, src/app/page.tsx, and src/app/ClientAppWrapper.tsx (SSR disabled via dynamic(..., { ssr: false })).
    • Remove legacy src/pages/* files.
  • Phaser Integration:
    • Refine PhaserGame lifecycle and event wiring; maintain React ↔ Phaser communication.
    • Add docs: phaser-nextjs-integration.md detailing architecture and modal usage.
  • Config:
    • Update tsconfig.json with Next plugin and includes.
  • Dependencies:
    • Upgrade phaser to ^3.90.0.

Written by Cursor Bugbot for commit 6549a67. This will update automatically on new commits. Configure here.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is being reviewed by Cursor Bugbot

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

icons: {
icon: "/favicon.png",
},
};
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Viewport Meta Tag Missing in Layout

The viewport meta tag, crucial for mobile responsiveness, is missing from the app/layout.tsx metadata. This tag was included in the previous pages/index.tsx and its absence can lead to improper rendering on mobile devices.

Fix in Cursor Fix in Web

@ospira
Copy link
Contributor

ospira commented Oct 10, 2025

Ports it to using app router. Can be kept in a separate branch and linked to in README.md for example.

Cannot target any other branch than main from here though.

Good luck! Just pointing out this is basically a dupe of a PR I made many months ago now: #3

It seems these sorts of PRs are not a priority at the moment for them, they are focused on new core releases and the editor. I definitely sympathize with the PR though, maybe you will have better luck on getting a merge than I, especially since yours appears in sync w the current main. 🫡

@justin-calleja
Copy link
Author

Hi @ospira - yep saw yours afterwards. Good to have a couple of references around. At least for me - not the most straightforward thing in the world to put a phaser game in a next.js app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants