Skip to main content

Dev Preview Tools

What you can do inside a Dev Preview panel: navigation and the toolbar, device emulation and viewport presets, find in page, the Element Picker, and the Output, Console and Diagnostics drawer, including stop, restart and clear-cache controls.

Updated
Reviewed

Toolbar

From left to right:

  • Back / Forward: move through page history. The tooltip names the page you would land on. Long-press either button, right-click it, or press ArrowDown on it for a list of earlier (or later) pages to jump to
  • Reload: refresh the current page. Shift+click does a hard reload that ignores the cache. While a page is loading the button becomes Stop loading
  • Address bar: shows the dev server's own address and route, such as localhost:5173/dashboard, even though the page is served from Daintree's proxy origin (see How the preview is served). Edit it and press Enter to navigate; only localhost addresses open here, and anything else is refused with "Only localhost addresses open here". Suggestions from this project's history appear as you type, matched against the address you see. Copy URL sits at the right end of the field. When the page zoom isn't 100%, a zoom chip appears there too; click it for zoom out, zoom in and Reset
  • Element Picker (dashed square with a pointer): switches the Element Picker on and off in this preview. Every Dev Preview has it
  • Device mode (phone icon, tooltip "Preview on a device"): turns device emulation on and off. See Device emulation
  • Console (terminal icon, tooltip "Show console"): opens and closes the drawer at the foot of the panel
  • Copy screenshot to clipboard (camera icon): captures the visible page and copies it to the clipboard as a PNG. Disabled until the webview is ready, and skipped on blank pages
  • Open in external browser: opens the page through a short-lived proxy bootstrap in your default browser. Application logins are separate from the embedded browser. See Opening the page in your real browser
  • More page actions (…): page zoom (Zoom in, Zoom out and Actual size, stepping through 25%, 50%, 75%, 100%, 125%, 150% and 200%) and Toggle DevTools (Chromium DevTools for the previewed page, in a detached window)

When the toolbar is narrower than about 640 pixels, Copy URL and the console toggle move into More page actions, so the route in the address bar stays readable.

Command-R Control-R Control-R reloads the focused dev preview without touching the server process.

Note
Screenshots go to the clipboard, not a file. Capture the page, then paste it straight into an issue, a chat, or a notes app.

Device emulation

Dev Preview emulates real mobile devices, not just their user agent. Turn on a preset and you get full Chromium device emulation: a real mobile viewport, the correct window.devicePixelRatio, proper viewport-meta handling, touch and pointer media features (pointer: coarse, hover: none), and mobile scrollbars. Swapping only navigator.userAgent would leave layouts looking like a narrow desktop window rather than a phone.

Click Device mode (phone icon) in the toolbar to turn emulation on. It starts on the last device you used, iPhone 17 the first time, and a second toolbar row appears under the first. Its Choose device menu lists four presets, each carrying the matching device dimensions and user-agent string:

PresetViewport (portrait)
Galaxy S26360 × 780
iPhone 17393 × 852
Pixel 10412 × 923
iPad Air 11"820 × 1180

With a device active, the page renders inside a rounded device frame, centered in the pane, with a label above it naming the device and its size (iPhone 17 · 393×852). The device row carries the current size and three more controls:

  • Rotate (tooltip "Rotate to landscape"): swaps width and height to switch between portrait and landscape
  • DPR: a 1× / 2× / 3× selector (default 1×) that sets the device scale factor, so high-DPR assets and srcset selection behave the way they would on the real device
  • Fit ("Scale the device down to fit the pane"): scales the device frame down to fit the pane, and adds the scale to the frame's label
Tip
Fit never upscales. It caps at 100%, so a small viewport stays at its real device size instead of stretching to fill the pane. Touch targets and type stay at a realistic scale rather than blurring up.

Device, rotation, DPR and fit are per-panel state that Daintree remembers. There is nothing to configure in Settings for device emulation. Click Device mode again (tooltip "Exit device mode") to return to the desktop layout.

Choose a device preset to preview the site at its viewport size.

Find in page

Press Command-F Control-F Control-F to search the current page. A floating find bar appears in the top-right of the webview with a Find in page field, a Match case (Aa) toggle, a match counter, previous and next buttons, and a close button. It searches as you type and shows the current position ("3 of 12"), or "No results". The shortcut works whether the Daintree UI or the embedded page has focus; pressing it again while the bar is open refocuses and selects the input.

The find bar is the same component the Browser panel uses, and the shortcut table there applies here too.

Element Picker

The Element Picker is built into every Dev Preview; there is no plugin to enable. Switch it on from its toolbar button and a strip appears under the toolbar, with a Browse / Inspect switch, the selection and its component trail. Select an element on the page and a drawer opens beside it. The drawer can be resized from its left edge; when the pane is too narrow to share, it floats over the page instead of squeezing the site through its own responsive breakpoints.

It traces the element as far as the page's framework exposes it, from a file and line checked against your source on a Svelte dev build to DOM-level picking on a page that names nothing, and hands a written request about it to a coding agent in the same worktree. See Element Picker for the full walkthrough.

Plugins don't add buttons to this toolbar. A plugin can teach the Element Picker a framework Daintree doesn't read itself, through the elementPickerProviders contribution point.

Output, Console and Diagnostics

The drawer at the bottom of the panel toggles from the Output drawer button, whose chevron shows the open/closed state, or from the toolbar's console toggle. It opens on its own when the server fails, and when a start has gone 15 seconds with no URL and no sign of compiling. It has three tabs:

  • Output: your dev server's terminal output, the same stream you would see if you ran the command yourself
  • Console: the previewed page's browser console, with a red badge carrying the current error count
  • Diagnostics: the session's lifecycle timeline and its current proxy state

A color-coded dot in the drawer header reports the server's state:

StateIndicatorMeaning
StoppedGrayServer not running. This includes a server that was running when Daintree last closed and has not been started again: nothing is reattached
StartingAmberProcess launched, waiting for the ready signal
InstallingAmberMissing packages detected; dependencies are being installed
RunningGreenServer is up and serving
StoppingAmberShutting the server process down
ErrorRedServer failed to start or crashed

While a restart is underway the header shows a Restarting label in amber.

Stop and restart

A Stop dev server button sits in the drawer header whenever the server is starting, installing, running or stopping, and is disabled while a restart is already in flight. Stopping doesn't clear your configured command, so the panel shows Start the dev server with a Start dev server button rather than falling back to the setup prompt. The stop sticks: Daintree won't start that server again on its own until you press Start or pick a restart option, even across a relaunch. See Stops that stick.

Beside it, Restart dev server kills the server process and relaunches it, and More restart options (…) opens a menu with four options:

  • Reload preview: reloads the page without touching the server process
  • Restart dev server: kills the server process and relaunches it
  • Restart and clear cache: relaunches after deleting framework build caches (.next, .vite, .turbo, .svelte-kit, .astro, .nuxt and node_modules/.vite)
  • Reinstall dependencies: relaunches after deleting node_modules and reinstalling

The last two ask for confirmation first and are disabled mid-install. The confirmation reads the dev server's folder before it offers anything, and says what it actually found:

  • Clear cache and restart? lists the caches that exist, with each directory's size and when it was modified and the total it frees, and confirms with Clear cache. When there are no caches to delete it becomes Restart dev server? and only restarts.
  • Reinstall dependencies? shows the folder, what it deletes, its size, the install command it runs and the lockfile it may update, and confirms with Reinstall dependencies. With no node_modules to delete it becomes Install dependencies?.

Size checks may still be pending or unavailable when the dialog opens. Daintree stops the server and waits for its port to become free before removing anything. These operations delete directories by their cache and dependency names, so keep hand-authored work out of them. Source files are not touched, though an install can rewrite the lockfile (or create one where there was none), and Git history is never a deletion target.

Warning
Restarting clears the terminal logs that explain what went wrong. When a start is stuck or a crash is unexplained, read the Output tab before you restart, or check the Diagnostics tab afterwards: the timeline survives the restart even though the logs do not.

Console tab

The Console tab captures the previewed page's browser console through the Chrome DevTools Protocol: the same messages DevTools would show, structured rather than flattened to text:

  • Level filters: All, Errors, Warn, and Log (Log includes info). Errors and Warn carry counts
  • Filter…: narrows messages by content
  • Message detail: a level badge (LOG / INF / WRN / ERR), a timestamp, the source file and line inline, an object inspector for logged objects, and collapsible console groups
  • Stack traces: offered only for errors, warnings and console.trace, where they say something. Runs of library frames fold into a single row you can expand. An uncaught exception opens with its frames showing
  • Copy: copy one message from its row, or every visible message from the toolbar
  • Clear console: empties the captured log

Capture holds roughly the last 500 messages per panel, survives switching tabs, and is cleared when the panel is deleted. Messages from a previous page are dimmed rather than dropped after a navigation.

Note
The Console tab shows the previewed page's console (your app's console.log calls and runtime errors). The Output tab shows the dev server's terminal output (build steps, compile errors, request logs). When something is wrong, check both. Console capture is specific to Dev Preview: Browser panels do not have it.

Diagnostics tab

Diagnostics answers "what just happened?" without asking you to reconstruct it from logs. The top of the tab, Session diagnostics, is a summary: status (marked (restored) for a session brought back from the last run), allocated port, detected URL, what the proxy would dial right now, the proxy's own port (and whether it fell back off 43000), and crash-loop state. Refresh diagnostics rereads it. Below it is the lifecycle timeline, newest first: ensure requested, config changed, port allocated, spawned, command submitted, first output received, install started and finished, URL detected, each readiness probe attempt and what it saw ("Server responded", "Server error response" or "No response", with the time left in the budget), ready and compile lines seen, compile started and finished, restart and stop requests, process exits, crash-loop backoff, a skipped bundler preference, and proxy failures. Errors are tinted; repeated identical events carry a ×N count.

Each session keeps its last 100 events, and Daintree retains rings for the 50 most recently touched sessions, so a timeline outlives the panel that produced it. Free-text detail is capped at 200 characters, and identical consecutive proxy failures inside a 10-second window coalesce into one counted row, so a retrying webview can't flush the lifecycle history that explains it.

A proxy 502 always names its cause:

CauseWhat it means
No session registered for this originThe origin isn't bound to a dev-preview panel, usually a stale tab or a page reopened after the panel was closed
Dev server isn't runningThe panel exists but its server is stopped, starting, or errored
Dev server refused the connectionThe port is not accepting connections, typically the server died or hasn't bound yet
Dev server timed outThe upstream accepted the connection but never answered within 30 seconds
Dev server connection failedAnything else, with the underlying error code attached

WebSocket upgrade failures are recorded the same way, which is what usually explains a preview that renders but never live-reloads.

Diagnostics shows the detected address, proxy routing and recent startup probes.