Skip to content

White screen on iOS Safari in Vite React App (SWC + Vite 5) — works on desktop and Android #20175

Closed as not planned
@Fenilsheta

Description

@Fenilsheta

Describe the bug

I'm building a Vite + React + SWC project. Everything works fine on desktop (Chrome, Firefox, Edge) and Android browsers.
However, on iOS Safari (13-17), the app loads as a blank white screen, even though Vite HMR console logs show “connected”.

I tested it on multiple iPhones. No error in devtools (remote inspect), just a blank page. Even reducing component size and removing large files didn’t help.

Reproduction

https://weekend-rental.vercel.app/

Steps to reproduce

Start Vite dev server on LAN.

Open the app URL on iOS Safari or iOS Chrome.

App shows white screen despite Vite saying "connected".

Same build works fine on Android and desktop.

System Info

System:
    OS: Windows 11 10.0.26120
    CPU: (8) x64 11th Gen Intel(R) Core(TM) i5-1155G7 @ 2.50GHz
    Memory: 1.75 GB / 15.65 GB
  Binaries:
    Node: 22.13.1 - C:\Program Files\nodejs\node.EXE
    npm: 11.2.0 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Chrome: 137.0.7151.57
    Edge: Chromium (134.0.3124.8)
    Internet Explorer: 11.0.26100.1
  npmPackages:
    @vitejs/plugin-legacy: ^5.4.3 => 5.4.3
    @vitejs/plugin-react-swc: ^3.5.0 => 3.7.1
    vite: ^5.4.1 => 5.4.10

Used Package Manager

npm

Logs

No visible error in Safari devtools.
Remote inspection only shows:

  • Vite client connected
  • HTML head rendered
  • No further JS execution

Validations

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions