惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
Google Developers Blog
WordPress大学
WordPress大学
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
小众软件
小众软件
人人都是产品经理
人人都是产品经理
美团技术团队
Blog — PlanetScale
Blog — PlanetScale
S
SegmentFault 最新的问题
博客园 - 【当耐特】
V
V2EX
Microsoft Azure Blog
Microsoft Azure Blog
博客园 - 叶小钗
Google DeepMind News
Google DeepMind News
量子位
罗磊的独立博客
月光博客
月光博客
N
Netflix TechBlog - Medium
大猫的无限游戏
大猫的无限游戏
博客园_首页
P
Proofpoint News Feed
Jina AI
Jina AI
云风的 BLOG
云风的 BLOG
博客园 - 司徒正美
腾讯CDC

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Cross-Platform Apps Don’t Need to Mean Cross-Platform UI
Rajaniraiyn · 2026-04-29 · via DEV Community

For a long time, cross-platform app development felt like choosing the least painful compromise.

You could maintain separate native apps for every platform and duplicate a lot of logic. Or you could use a cross-platform framework and accept its trade-offs: runtime overhead, abstraction leaks, slower access to new platform APIs, and an app that sometimes felt native-adjacent rather than native.

Electron, Capacitor, CEF, React Native, Flutter, and Compose Multiplatform all solved real problems. They still do. The point is not that these tools are bad.

The point is that the center of gravity is shifting for a certain class of apps: developer tools, terminals, editors, local-first software, creative tools, and other products where performance, platform feel, and long-term control matter.

A different architecture is becoming more practical:

one shared systems-level core, surrounded by thin native UI layers.

The core is usually written in Rust, Zig, C++, or another systems language. It owns the hard, reusable parts of the product: state, persistence, sync, parsing, rendering primitives, business rules, protocols, file formats, and tests.

Each platform then gets a small native shell:

  • macOS gets SwiftUI/AppKit.
  • Android gets Jetpack Compose.
  • Linux gets GTK, Qt, or another native toolkit.
  • iOS gets SwiftUI/UIKit.
  • Web may get WASM where it makes sense.

The UI layer becomes mostly presentation and platform integration. The product logic lives in one place.

That distinction matters.

The cost of owning the entire UI stack

Recent developer tools show both sides of this trade-off.

Zed built GPUI: a custom GPU-accelerated Rust UI framework with its own rendering, layout, input, and text infrastructure. Warp built a custom Rust-based UI stack with GPU rendering to deliver its block-based terminal experience.

These are impressive engineering efforts. They also show how expensive this path can become.

Once you build your own UI framework, you are no longer just building your product. You are also maintaining a rendering engine, text system, accessibility story, windowing layer, input model, drag-and-drop behavior, platform backends, and all the edge cases that native toolkits have accumulated over decades.
That cost is sometimes worth paying. Zed and Warp are deeply UI-driven products. Their performance goals and interaction models may justify a custom stack.

But it is not a small decision. “We need it to be fast” can easily become “we now own a cross-platform app framework.”

That is a very different business.

Ghostty is the more interesting counterexample

Ghostty takes a different approach.

The complex terminal logic lives in a shared Zig library: libghostty. The platform UI remains intentionally native and relatively thin. On macOS, Ghostty uses Swift with AppKit and SwiftUI. On Linux, it uses Zig with GTK4.

That architecture is not as glamorous as inventing a new UI framework. But it is extremely pragmatic.

Ghostty still gets native platform integration. It still gets high performance. But it avoids reimplementing every primitive of desktop UI from scratch.

The key idea is not “write everything once.”

The key idea is **reuse the parts that should be shared, and keep the parts that should feel native close to the platform.

That is a much healthier abstraction boundary.

The browser engine is not always the right abstraction

Electron won because it made shipping desktop software dramatically easier. It gave teams one UI technology, one rendering model, and access to the web ecosystem.

That was a good trade for many products.

But for performance-sensitive tools, bundling an entire browser engine can feel increasingly heavy. You inherit memory usage, startup cost, packaging weight, and a layer of indirection between your product and the operating system.

The alternative is not necessarily “go fully native everywhere.”

The alternative is to ask a more precise question:

What part of this application actually needs to be cross-platform?

For many apps, the answer is not the UI.

It is the core.

The parser.
The sync engine.
The storage layer.
The protocol implementation.
The terminal emulator.
The indexing engine.
The collaboration model.
The domain logic.

Those are the parts that benefit most from being shared, tested once, and reused everywhere.

The buttons, menus, windows, gestures, shortcuts, permissions, notifications, file pickers, accessibility behavior, and platform-specific affordances often benefit from being native.

FFI is getting good enough

This architecture used to be painful. The boundary between a Rust or Zig core and Swift/Kotlin/native UI code was full of manual glue, unsafe edges, awkward type mapping, and build-system friction.
That is changing.

Mozilla’s UniFFI has made Rust shared components more accessible by generating bindings for languages like Swift and Kotlin. BoltFFI is a newer project pushing in the same direction with a focus on lower overhead and more native-feeling generated bindings.

The tooling is not perfect. FFI still forces discipline. You need to design stable APIs, think carefully about ownership, threading, async boundaries, error types, and data serialization.

But it is no longer exotic.

A small team can now realistically write a core library in Rust or Zig, generate bindings, and expose a clean surface area to native UI code.

That changes the economics.

AI makes the thin-layer model more practical

There is another under-discussed reason this architecture is becoming more attractive: AI reduces the maintenance cost of thin platform layers.

If the core behavior is already implemented and tested, the native UI work becomes more mechanical. A developer can build the feature on one platform, then use an AI agent to draft equivalent SwiftUI, Compose, or GTK changes for the others.

This does not remove the need for platform expertise. Generated UI code still needs review. Native details still matter.
But it changes the ratio.

Maintaining three thin native shells is much less scary when most product behavior lives in a shared core, and the platform-specific code is small enough to review carefully.

AI is bad at replacing product judgment. It is much better at translating known patterns across similar surfaces.

That is exactly where thin native UI layers fit.

This is not a universal replacement

There are still many cases where Electron, Flutter, React Native, or KMP are the right call.

If your team is web-heavy and needs to ship fast, Electron may be the pragmatic choice.
If your product is mostly forms, dashboards, or CRUD workflows, a cross-platform UI framework may be more than good enough.
If your UI itself is the hard part, a custom rendering stack may be justified.
If your team does not want to own systems-level code, a shared Rust or Zig core may create more problems than it solves.

The shared-core/native-shell model is not free. It asks you to own more of your architecture. It rewards teams that care about API boundaries, testing, platform conventions, and long-term maintainability.

But for the right category of software, it is a compelling middle path.

You do not have to duplicate your entire app.
You do not have to bundle a browser.
You do not have to pretend every platform is the same.

You can share the engine and let each platform be itself.

That is the interesting shift.

The future of cross-platform software may not be one framework that abstracts every platform away.

It may be one core that gives every platform something native to wrap.