Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removal of apple-mobile-web-app-capable results in splash screens not working #74524

Open
jwanner83 opened this issue Jan 4, 2025 · 0 comments
Labels
bug Issue was opened via the bug report template. Metadata Related to Next.js' Metadata API.

Comments

@jwanner83
Copy link

Link to the code that reproduces this issue

https://github.com/jwanner83/next-apple-web-app-issue

To Reproduce

  1. Checkout this repo https://github.com/jwanner83/next-apple-web-app-issue

Working example with workaround

ScreenRecording_01-04-2025.22-37-41_1.MP4

In this example, I am adding the required meta tag in the root layout through html: https://github.com/jwanner83/next-apple-web-app-issue/blob/main/working-with-workaround/app/layout.tsx#L167

  1. Go to working-with-workaround
  2. pnpm i
  3. pnpm dev
  4. Visit the page with an iPhone and add the page to the home screen
  5. Open the linked page <- You will see a yellow screen on startup of the page

Not working example

ScreenRecording_01-04-2025.22-38-47_1.MP4

In this example, I am simply using the appleWebApp property inside the Metadata object. https://github.com/jwanner83/next-apple-web-app-issue/blob/main/working-with-workaround/app/layout.tsx#L6 (This used to work before v15.0.0 / before the pull request #70363 was merged and released)

  1. Go to not-working
  2. pnpm i
  3. pnpm dev
  4. Visit the page with an iPhone and add the page to the home screen
  5. Open the linked page <- You will see a black screen on startup of the page, not the desired yellow startup image.

Current vs. Expected behavior

I understand that the tag apple-mobile-web-app-capable is marked as deprecated and should be replaced with mobile-web-app-capable but for the sake of not breaking things, that safari requires, I would want the tag to be added in addition to the mobile-web-app-capable.

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 24.2.0: Fri Dec  6 19:02:12 PST 2024; root:xnu-11215.61.5~2/RELEASE_ARM64_T6031
  Available memory (MB): 36864
  Available CPU cores: 14
Binaries:
  Node: 20.18.1
  npm: 10.8.2
  Yarn: 1.22.22
  pnpm: 9.15.2
Relevant Packages:
  next: 15.1.1-canary.25 // Latest available version is detected (15.1.1-canary.25).
  eslint-config-next: N/A
  react: 19.0.0
  react-dom: 19.0.0
  typescript: 5.3.3
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

Metadata

Which stage(s) are affected? (Select all that apply)

next dev (local), next start (local), Vercel (Deployed)

Additional context

The pull request #70363 which fixes the issue #70272 changed from the meta tag <meta name="apple-mobile-web-app-capable" content="yes" /> to <meta name="mobile-web-app-capable" content="yes" /> because apparently chrome tells the user that apple-mobile-web-app-capable is deprecated and should be replaced with mobile-web-app-capable. It was released with v15.0.0-canary.175 / v15.0.0

Unfortunately, the extremely bad documented apple splash screen feature for pwa https://developer.apple.com/library/archive/documentation/AppleApplications/Reference/SafariWebContent/ConfiguringWebApplications/ConfiguringWebApplications.html doesn't work when the <meta name="apple-mobile-web-app-capable" content="yes" /> isn't set.

The problem only occurres on iPhone devices.

@jwanner83 jwanner83 added the bug Issue was opened via the bug report template. label Jan 4, 2025
@github-actions github-actions bot added the Metadata Related to Next.js' Metadata API. label Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue was opened via the bug report template. Metadata Related to Next.js' Metadata API.
Projects
None yet
Development

No branches or pull requests

1 participant