NoWayOS
EN
GitHub
MenuClose

13 November 2026

React in, Rust out

Designers keep React. Devices get native Rust. How the Screen Compiler turns screens into code at build time, so there's no browser on the device to attack.

Modern interfaces are designed in React. So a great many dedicated devices, from control panels to ticket machines, ship a whole browser engine, one of the largest and most attacked programs there is, to draw a few buttons and the words "Touch Start to begin".

We wanted the modern design workflow without the browser. So we built the Screen Compiler.

Write the screen in React

Your designers and front-end developers keep their tools: components, props, design tokens, their editor. They write the screen in TSX (this one is shortened from one of the Screen Compiler's test screens):

<Column gap={SPACE_SM} padding={SPACE_LG}>
  <Text id="title">Welcome</Text>
  <Text>Touch Start to begin.</Text>
  <Spacer />
  <Button id="start" onPress={onStart}>Start</Button>
</Column>

Ship plain Rust

At build time, on your machine or in CI, the Screen Compiler turns that into Rust for NoWayOS's user interface runtime:

let n1 = b.text("Welcome")?; // welcome.tsx:17:9 <Text>
let n2 = b.text("Touch Start to begin.")?; // welcome.tsx:18:9 <Text>
let n4 = b.spacer(None)?; // welcome.tsx:20:9 <Spacer>
let n5 = b.button("Start", actions::START)?; // welcome.tsx:21:9 <Button>

Every line points back to the TSX it came from. The device gets that code and nothing else: no JavaScript engine, no browser, no web page to attack. The Screen Compiler itself never ships.

React in, Rust out

The browser stays behind at the build.

At build time

  1. Screen in TSXReact, as designers write it

  2. Screen CompilerExact, or nothing

  3. Plain RustTraced to its TSX line

Outside the subset: refused, with its file, line and column

On the device

NoWayOS UI runtimeNo browser. No JavaScript.

The Screen Compiler runs at build time and never ships. A picture of the flow.

Exact, or nothing

A converter that guesses is a converter you can't trust. The Screen Compiler converts its declared subset of TSX exactly, and refuses everything else with the file, line and column. It never approximates. The Rust it writes has no unsafe, no unwrap and no panic.

Then every converted screen is drawn by NoWayOS's renderer and compared, pixel for pixel, with its approved image. If a single pixel moves, the build says so.

Where it stands

The Screen Compiler is in development: its first subset is built and the next is under way. It's open source under MIT, on GitHub beside NoWayOS. If your team designs in React and builds devices that matter, we'd like to hear from you.