Build with XuiView Markdown

Platform support and fallbacks

Build one shared app while making each platform promise deliberately. Core describes contracts; each runtime decides which services and operations it can supply.

Ask for a capability

Resolve an optional service from the current window or view, check whether it exists, and choose a fallback before the user reaches a dead end. For example, an optional GPU effect can use a Canvas illustration, while a required 3D editor should show an unavailable state and keep its document accessible.

Do not infer capabilities solely from “desktop,” “phone,” or the operating system name. A desktop browser may disable WebGL. A phone emulator supplies simulated geometry while its host still owns native resources.

Keep the limits visible

Area Practical boundary in the current repository
GPU Backend-specific features; Android Vulkan currently supports a restricted cube-style path
Browser windows One top-level window per canvas; native extra-window patterns do not transfer directly
Text editing Runtime bridges differ; test IME and soft keyboards on actual targets
Trackpads Browser wheel events do not supply the native phase/momentum contract
Accessibility Keyboard/focus design helps, but complete native semantic bridges are not implemented across runtimes
SVG capture Software vector output, not a validation of native blur or hardware GPU pixels

Treat this as a set of design constraints, not a reason to hide errors. Unsupported operations should have an understandable response. A caught exception followed by an empty region makes both humans and automated tests guess what happened.

Test the claim you ship

For each required feature, identify the implementing runtime, exercise the smallest representative case, and record the actual target. Software tests establish shared behavior; emulator tests establish emulated behavior; native tests establish the tested native path.

Keep platform selection and adapters at the app's edge. Let shared views request app-level services with clear semantics. That structure makes it possible to add support later without rewriting page code.

Use the GPU path guide, browser deployment guide, and topic-specific input articles for concrete examples.