Mobile testing
localhost only exists on the machine it runs on, so a phone cannot reach your
dev server through it. Expose the route and the device gets a real HTTPS URL.
Expose the dev server
Section titled “Expose the dev server”Configure a public server first using Exposing publicly.
routeup serve example-app --port 3000 --exposeThis example assumes your saved token allows *.mukul.routeup.dev.
route: example-applocal: https://example-app.localhostpublic: https://example-app.mukul.routeup.devexpose: all pathstargets: / http://localhost:3000
requests: livepress Ctrl-C to stopOpen it on the device
Section titled “Open it on the device”Open the public URL in Safari or Chrome. No local profile or CA installation is needed because the public certificate is publicly trusted.
Because it is a publicly trusted HTTPS origin, it exercises secure-context
features such as service workers, getUserMedia, secure cookies, and the
clipboard API. Hostname, cookie-domain, and cross-site behavior can still differ
from production.
Why not local for this
Section titled “Why not local for this”A *.localhost route is the zero-network path, but it resolves to 127.0.0.1 on
each machine and is unreachable from a separate device. Mobile testing needs the
public route. (Same-LAN shortcuts like mDNS are a possible future addition, but
today off-host devices go through the public server.)
Tip: keep the URL stable
Section titled “Tip: keep the URL stable”Bookmark the named public URL. The configured route and namespace let you request the same URL each run instead of receiving a new random URL; claims remain subject to the server’s normal conflict rules.