
This tool works with both Expo and React Native CLI projects. Just install and go.
Inspect layout boundaries on the running app. Debug Borders draws colored borders and labels over your running app, then lets you tap any label to inspect the component underneath — its testID, styles, position, and accessibility info — without leaving the device.
On web, borders also show on plain DOM nodes. They do not show objects inside the 3D scene.
npm install @buoy-gg/debug-bordersThat's it. Debug Borders appears in your FloatingDevTools menu.
Tap the BORDERS icon in the floating menu to cycle through modes:
| Mode | What you see |
|---|---|
| Off | No border overlay |
| Borders | Rainbow-colored borders on every component, colored by depth in the tree |
| Labels | Borders + labels, but only for components with a testID or accessibilityLabel |
Borders are touch-through — they never interfere with interacting with your app — and they track layout changes automatically.
Labels mode filters the noise down to components you've actually identified:
testID, pink for accessibilityLabelTap any label to open a full inspection modal for that component:
testID, accessibilityLabel, nativeID, and keyUse it to answer "what testID does QA need for this button?" or "which component owns this padding?" straight from the device.
Want your own naming or colors? Build the tool with createDebugBordersTool:
import { createDebugBordersTool } from "@buoy-gg/debug-borders";
const layoutTool = createDebugBordersTool({
name: "LAYOUT",
description: "Layout visualizer",
offColor: "#9ca3af",
bordersColor: "#ec4899",
labelsColor: "#8b5cf6",
id: "debug-borders",
});
import { createDebugBordersTool } from "@buoy-gg/debug-borders";
const layoutTool = createDebugBordersTool({
name: "LAYOUT",
description: "Layout visualizer",
offColor: "#9ca3af",
bordersColor: "#ec4899",
labelsColor: "#8b5cf6",
id: "debug-borders",
});
Pass it to FloatingDevTools via the apps array and it replaces the default preset.
Install @buoy-gg/debug-borders and tap the BORDERS icon to cycle modes — Borders draws depth-colored outlines on every component, and Labels narrows that to components with a testID or accessibilityLabel. The overlays are touch-through, so your app stays usable.
Yes — tap any label to inspect the component underneath on the device itself: its testID, styles, position, and accessibility info. Nothing has to be attached to your machine.
Import @buoy-gg/core/web/register before React DOM. The buoy() Vite plugin adds it for you. The shared overlay measures DOM elements and draws their borders and labels. Import it from the package's /web entry (7.0.41 or later). See Web installation for registration, dependencies, and browser boundaries.