# NativeDesktop > One Rust view tree, native on macOS (AppKit), Linux and Windows (GPUI), and plain GPUI on the web. Every page below is markdown. All of them in one file: https://nativedesktop.formalsnake.dev/llms-full.txt. Building an app with nd: start at https://nativedesktop.formalsnake.dev/agents/index.md. ## Start - [NativeDesktop](https://nativedesktop.formalsnake.dev/index.md): One Rust view tree that renders as native AppKit controls on macOS and through GPUI on Linux, Windows and the web. - [Getting started](https://nativedesktop.formalsnake.dev/getting-started.md): Install the nd CLI, create an app, run it on the desktop and in a browser, and run its tests. ## Concepts - [Programming model](https://nativedesktop.formalsnake.dev/concepts/programming-model.md): Views, entities and contexts, what render returns, and how the retained tree reaches a backend. - [Elements](https://nativedesktop.formalsnake.dev/concepts/elements.md): The element vocabulary: div, flex helpers, text, styling, layout, identity and children. - [State](https://nativedesktop.formalsnake.dev/concepts/state.md): Entities and observation, controlled values, background work, clocks, errors and saved state. - [Actions and keys](https://nativedesktop.formalsnake.dev/concepts/actions-and-keys.md): Declare actions, bind keys in contexts, build menus from the same actions, and move focus. - [Theming](https://nativedesktop.formalsnake.dev/concepts/theming.md): The design tokens apps read with cx.theme(), where their values come from on each OS, and how to change them. - [Overrides](https://nativedesktop.formalsnake.dev/concepts/overrides.md): Every way to change how a native default looks or behaves, from one element's style up to the whole app, and when each is the right one. - [Patterns](https://nativedesktop.formalsnake.dev/concepts/patterns.md): How window structure such as the toolbar, sidebar, inspector and titlebar is declared once and drawn by each OS. - [Native widgets](https://nativedesktop.formalsnake.dev/concepts/native-widgets.md): How an app defines its own widget with the NativeWidget trait: a drawn version for every OS and a native view where the OS has one. - [Swift](https://nativedesktop.formalsnake.dev/concepts/swift.md): When and how an app adds Swift to its macOS build, using a SwiftUI gauge as the worked case. ## Components - [Components](https://nativedesktop.formalsnake.dev/components/index.md): The built-in components by group, which are the OS's own control on macOS and which are drawn, and where to see each one. - [Component reference](https://nativedesktop.formalsnake.dev/components/reference.md): Every built-in element constructor and its builder methods, generated from nd-components. ## Guides - [Virtualization](https://nativedesktop.formalsnake.dev/guides/virtualization.md): Lists, tables, grids and trees over keyed rows: ListState, versions, tail following, jump targets, selection, row actions and how the macOS and GPUI presenters differ. - [Overlays](https://nativedesktop.formalsnake.dev/guides/overlays.md): Popovers, panels, tooltips, context menus, the command palette and toasts: how they open, how they close, and why a click inside one never reaches the page or button under it. - [Gestures](https://nativedesktop.formalsnake.dev/guides/gestures.md): Tap, double tap, long press and drag, trackpad pinch, rotate and page swipes, momentum scrolling, haptics, and the focus rules that go with them. - [Windows and tabs](https://nativedesktop.formalsnake.dev/guides/windows-and-tabs.md): Opening windows with WindowOptions, several windows and monitors, window controls and drag regions, window tabs with tab_group, and the in-window tab, split and pane widgets. - [Webview](https://nativedesktop.formalsnake.dev/guides/webview.md): Show web pages in a window with WebView and webview(): the app-owned handle, commands, events, WKWebView and CEF, and what Linux and Windows do not have yet. - [Terminal](https://nativedesktop.formalsnake.dev/guides/terminal.md): Show a shell or any byte stream in a window with nd-terminal: TerminalSession, terminal(), theme colours, input, and what runs on which OS. - [System](https://nativedesktop.formalsnake.dev/guides/system.md): Dialogs, clipboard, notifications, keychain, tray, media keys, audio and OS events through nd::system, plus plugins for what the framework does not ship. - [Settings and config](https://nativedesktop.formalsnake.dev/guides/settings-and-config.md): The app manifest, user settings as a TOML file with layers and Nix support, machine state, local sockets and SQLite. - [Packaging](https://nativedesktop.formalsnake.dev/guides/packaging.md): Build installers for macOS, Linux and Windows with nd package, and ship signed delta updates from a static feed with nd release. - [Web](https://nativedesktop.formalsnake.dev/guides/web.md): Build the same app for the browser with nd build --target web: one canvas, the plain GPUI look, and checks for what a browser cannot do. ## Tooling - [The nd command](https://nativedesktop.formalsnake.dev/tooling/cli.md): Every nd subcommand with its flags and one example each. - [Testing](https://nativedesktop.formalsnake.dev/tooling/testing.md): The three test tiers, goldens, real input, the nd-test locators, the MCP bridge and how nd test runs them. - [Diagnostics](https://nativedesktop.formalsnake.dev/tooling/diagnostics.md): What nd-diag records in every app without code, and how to read an incident bundle after a panic, crash or hang. - [Performance](https://nativedesktop.formalsnake.dev/tooling/performance.md): The frame budgets nd apps hold, the numbers measured so far on e1504g, g815 and the macbook, and how to measure your own app. ## For agents - [For agents](https://nativedesktop.formalsnake.dev/agents/index.md): What a coding agent gets from nd new, and how to point one at an nd project. - [Patterns](https://nativedesktop.formalsnake.dev/agents/patterns.md): How an nd app is put together: system structure, entities, actions, controlled values, overlays and time. - [Widgets](https://nativedesktop.formalsnake.dev/agents/widgets.md): Which element to use, virtual lists, and app-defined native widgets that never echo. - [Testing](https://nativedesktop.formalsnake.dev/agents/testing.md): The three test tiers, the machine lock, and reading the incident bundle before reproducing a bug. - [Styling](https://nativedesktop.formalsnake.dev/agents/styling.md): Theme tokens, the appearance audit, override layers and glass. - [Performance](https://nativedesktop.formalsnake.dev/agents/performance.md): Budgets on the slowest machine, per-view rendering and keeping the main thread free. - [Don'ts](https://nativedesktop.formalsnake.dev/agents/donts.md): The hard list, with the nd check rule that fires for each. ## Examples - [Examples](https://nativedesktop.formalsnake.dev/examples.md): Every example app in the repository, live on the web and captured on each OS.