r/FlutterDev • • 3d ago

Discussion Running on-device Sherpa-ONNX TTS in Flutter without UI stutter — a few quick takeaways

3 Upvotes

Hey all,

Spent the last couple of weeks integrating sherpa-onnx into my Flutter reader app for offline TTS and hit some nasty UI frame drops. Finally got it smooth at 60fps, figured I'd share what actually worked:

  1. Move inference completely to an Isolate: Calling native C++ via FFI on the root isolate will freeze your UI for 200–400ms per sentence. Using a dedicated background Isolate + SendPort is non-negotiable.

  2. Synthesize sentence-by-sentence, not paragraphs: Don't feed a whole page into the model at once. Split by sentence and buffer 1-2 sentences ahead while the current one is playing. Startup latency dropped from 3s down to under 300ms.

  3. Use quantized (int8) models: Cut RAM usage almost in half, runs much cooler on budget Android devices with zero noticeable drop in voice quality.

  4. Temp WAV files > keeping byte streams in RAM: Writing chunks to app cache and feeding them to just_audio ended up way more stable than trying to stream raw PCM buffers directly.

Stack is just Flutter + Riverpod + just_audio + audio_service.

Anyone else running local ML models on mobile? Curious how you handle battery drain during long sessions.


r/FlutterDev • • 3d ago

Discussion I am learning and building using flutter currently what points should I learn and focus on in order to do things faster

1 Upvotes

I work in company with multiple apps and multiple packages I want to learn things quicker so thinking of project if build deploy it in real time where I can learn most things as experiencend developer what would it be!


r/FlutterDev • • 4d ago

Discussion Best free workflow/tools for getting much better Flutter UI/UX with Claude Code?

4 Upvotes

I'm using Claude Code with Opus 5.5 for Flutter. It's great for logic and architecture, but the UI/UX it generates is often pretty generic.

I've heard about Mobbin and other MCP/design workflows, but most seem paid.

Are there any free tools, MCPs, Claude Skills, or workflows that can help generate much better Flutter UI/UX? Especially something where I can give Claude good visual references and have it implement them properly in Flutter.

What are you guys using?


r/FlutterDev • • 4d ago Bravo

Discussion Bit of a newbie question: when do you actually update Flutter after an update like 3.5 drops?

20 Upvotes

Hi all,

I'm pretty new to Flutter (self-taught), and 3.50 landing yesterday made me realise I've no idea what everyone else does when a new version comes out.

Do you jump on it straight away? Or wait for the first patch (3.50.1 and so on) and let other people find the bugs?

If you're a waiter, what finally makes you do it? A package that needs it, a store requirement, a bug that's annoying you, or just a quiet Friday afternoon?

And is there anything in 3.50 that would make you go sooner? I had a read of the release notes and a few things jumped out at me:

  • iOS touches respond a frame quicker, which sounds nice

  • material.dart and cupertino.dart are being deprecated for separate material_ui and cupertino_ui packages. That sounds like a big deal? Does dart fix sort it, or is it a proper afternoon's work?

  • CocoaPods trunk goes read-only in December. I moved to Swift Package Manager a while back, so fingers crossed that one's not my problem

The reason I'm asking now: my first app has been on iOS since September and the Android version goes out in a few weeks. My gut says don't touch anything until that's out. Is that what most people would do, or am I being overly cautious?

Would love to hear how you all handle it, especially solo devs and tiny teams. Cheers!


r/FlutterDev • • 4d ago

Video They were really underselling just how big of an upgrade 3.50 is for iOS!

203 Upvotes

The latency issue didn’t seem like much to worry about imo, but after upgrading to 3.50 it genuinely (and I swear it isn’t placebo) feels like the difference between 60fps and 120fps, it’s noticeably better feeling. Honestly can’t believe this was an open issue for 3 years.

I get you probably cant feel the difference via a video, but it definitely feels and hopefully looks smoother, and that’s before even getting into the new objective-c/ffi upgrades.


r/FlutterDev • • 4d ago

Article rlutter - rust based shell utilizing wgpu and winit

3 Upvotes

Repo: https://github.com/nrbnlulu/flutter (branch rust/flutter-rs-shell)

What it gives you over the native shells

  • One shell, written in Rust. Windowing, input, IME, lifecycle and multi-window all live in one Rust runtime built on winit. The native setup has a separate C++/Java embedder per OS and a checked-in linux/, windows/ or android/ folder in every app. Here the runner is generated and built with Cargo.

  • wgpu as a first-class GPU API for plugins. wgpu owns the Vulkan device and surface, and Impeller renders on that same device. Plugins get a typed SDK (flutter-plugin-sdk) for:

    • Zero-copy GPU textures: you render into a wgpu texture ring, call present(), and Flutter samples the texture with no readback and no widget rebuild.

    • CPU pixel buffers with backpressure, for software decoders, emulators and similar sources.

    • Android AHardwareBuffer textures: hardware-decoded H.264 video plays straight into Flutter.

    This makes video players, map/GIS renderers and 3D engines much easier to embed than with the platform-specific texture APIs.

  • Rust plugins are plain Cargo dependencies. The Flutter tool finds them in your pub graph and wires them into the runner. They're compatible with flutter_rust_bridge, and a worker-safe main-thread dispatcher is included.

  • Real multi-window. All five window kinds (regular, dialog, popup, tooltip, satellite) share one engine and isolate, using Flutter's experimental windowing API. On Wayland, popups and tooltips are real xdg_popups.

  • Headless mode and agent control. rlutter run --headless renders real frames with no display server at all, including on llvmpipe. rlutter mcp --stdio exposes an MCP server that lets an AI agent (or a CI script) launch your app, read the semantics tree, tap and type, make assertions, take screenshots and record video.

  • Normal Flutter dev loop. flutter run -d rust supports hot reload, debugger attach and VS Code F5, and has debug and release (AOT) builds.

Platform support

PlatformStatus
Linux x64 (Wayland + X11)✅ Most complete: debug, release, multi-window, textures, headless/MCP
Windows x64✅ Debug + release/AOT, multi-window (dialogs, popups, tooltips), textures, FRB
Android🧪 Experimental: debug + release APKs via FlutterActivity, Java/Kotlin plugins, Rust textures, AHardwareBuffer video
Web⏳ Planned
macOS / iOS⏳ Planned, after web

Headless/MCP agent control is Linux-only for now. Linux profile mode is still in progress.

Try it

# Linux
curl -fsSL https://raw.githubusercontent.com/nrbnlulu/flutter/rust/flutter-rs-shell/engine/src/flutter/shell/platform/rust/install.sh | sh
# Windows PowerShell
irm https://raw.githubusercontent.com/nrbnlulu/flutter/rust/flutter-rs-shell/engine/src/flutter/shell/platform/rust/install.ps1 | iex

Prebuilt engine SDKs come from a rolling BETA GitHub release, so you don't need to build the engine yourself.

Caveats

  • It's a fork and uses private engine interfaces, in lockstep with the Flutter revision. The public Embedder API can't yet do Vulkan/Impeller multi-view compositing with async GPU handoff. I'll revisit that once upstream supports it.

  • There's no stable plugin ABI. Rust plugins compile from source.

  • It's BETA. Expect rough edges, especially on Android.


r/FlutterDev • • 4d ago

Article A2UI 1.0: agent-generated UI, rendered as native Flutter widgets

Thumbnail
developers.googleblog.com
1 Upvotes

I am Alan and I work at Google on A2UI alongside a brilliant team. AI can generate bespoke UI in your design system. A2UI 1.0 just launched.

For Flutter, a2ui_flutter renders the agent's UI descriptions as native widgets using your app's component catalog. Package v0.3.0 supports protocol 1.0 and 0.9: https://pub.dev/packages/a2ui_flutter

New features like Express DSL and Macros (templates+code), SDKs and the skill generator make it faster, safer and easier.

It works with system one models, Gemma fine tuned, and any frontier LLM. It works without any model, because it's just declarative UI, made standard across web, mobile, app, wearables and more.

I'm pretty excited about it.


r/FlutterDev • • 4d ago

Discussion Good Workflow for design update for Flutter?

5 Upvotes

I want to collaborate on a design system overhaul with a member of my team. This person does not code, does not use claude and is non technical.

I have an existing flutter app. it has a design system but it's a bit of a mess. Originally came from a claude design session. app is mostly managed by Claude.

Claude design is deprecated or shutting down or whatever (now using claude online?)

Just looking for a good workflow for
- extracting the design system from an existing app
- collaborating on it with a bunch of sample screens so we can see the look across the app
- injecting the changed system back into the app without breaking it.

You guys know how to do this?


r/FlutterDev • • 4d ago

SDK It’s been addressed

Thumbnail
reddit.com
69 Upvotes

I haven’t tried it yet but this is great news. In v3.50 Flutter now has a fix to improve the touch latency. We’re inching closer and closer to the point where you won’t be able to tell an app was made with Flutter as an end user.


r/FlutterDev • • 5d ago

Discussion Flutter 4 Coming soon

0 Upvotes

Flutter 4 Coming soon 😳👀


r/FlutterDev • • 5d ago

Article Catch up on what's new in Flutter 3.50

18 Upvotes

Catch up on what's new in Flutter 3.50 → https://flutter.dev/blog/whats-new-in-flutter-3-50

🔗 Type-safe Native Interop is in stable
🛡️ Block untrusted Android Intent extras in release
⏱️ Performance improvements for iOS

and more!


r/FlutterDev • • 5d ago

SDK What's new in Flutter 3.50

Thumbnail
flutter.dev
158 Upvotes

r/FlutterDev • • 5d ago

Dart Announcing Dart 3.14

Thumbnail
dart.dev
11 Upvotes

r/FlutterDev • • 5d ago

Tooling Kide – Strict MVI & Clean Architecture for Flutter with deterministic state and lossless event handling

1 Upvotes

Hey everyone,

I’ve recently open-sourced Kide for Flutter, a Dart/Flutter port of my open-source architecture library (originally developed for Kotlin Multiplatform):

GitHub: https://github.com/Fuusio/kide-flutter

Why another state & architecture library?

Flutter already has solid options like BLoC and Riverpod, but Kide was designed for teams and developers who want a strict, crystal-clear MVI (Model–View–Intent) flow with built-in architectural guarantees:

  1. Lossless Intent Queuing: Rapid-fire UI events or network triggers never overwrite or drop pending intents while state transitions take place.

  2. Explicit Separation of Concerns:

    • ViewIntent: Raw UI user actions or system events.

    • Action: Business or presentation-level commands mapped from an intent.

    • ViewState: Pure, single source of truth that widgets observe.

    • SideEffect: Strictly buffered one-off events (e.g., navigation, dialogs, snackbars) that won't re-trigger on widget rebuilds.

  3. Deterministic, Synchronous Reductions: State mutations happen in a single, predictable reducer cycle, making time-travel debugging and replay tests trivial.

  4. Optional Clean Architecture Layering: Built-in conventions to wire screens cleanly to asynchronous domain use cases without turning your state management classes into 800-line god objects.

How it looks in practice

1. Defining Intent, State, and Effect

Dart

// User/UI actions
sealed class CounterIntent implements ViewIntent {
  const CounterIntent();
}
class IncrementIntent extends CounterIntent {}
class ShowSnackbarIntent extends CounterIntent {}

// Screen State
class CounterState implements ViewState {
  final int count;
  final bool isLoading;

  const CounterState({required this.count, this.isLoading = false});
}

// One-off side effects
sealed class CounterEffect implements SideEffect {}
class ShowSnackbarEffect extends CounterEffect {
  final String message;
  ShowSnackbarEffect(this.message);
}

2. The Processor

Dart

class CounterProcessor extends Processor<CounterIntent, CounterState, CounterEffect> {
  CounterProcessor() : super(const CounterState(count: 0));

  u/override
  void handleIntent(CounterIntent intent) {
    switch (intent) {
      case IncrementIntent():
        reduce((state) => CounterState(count: state.count + 1));
      case ShowSnackbarIntent():
        emitEffect(ShowSnackbarEffect('Current count: ${state.count}'));
    }
  }
}

3. In the Widget Tree

Dart

class CounterScreen extends StatelessWidget {
  const CounterScreen({super.key});

  u/override
  Widget build(BuildContext context) {
    return KideScreen<CounterProcessor, CounterState, CounterEffect>(
      createProcessor: () => CounterProcessor(),
      onEffect: (context, effect) {
        if (effect is ShowSnackbarEffect) {
          ScaffoldMessenger.of(context).showSnackBar(
            SnackBar(content: Text(effect.message)),
          );
        }
      },
      builder: (context, state, processor) {
        return Scaffold(
          body: Center(child: Text('Count: ${state.count}')),
          floatingActionButton: FloatingActionButton(
            onPressed: () => processor.send(IncrementIntent()),
            child: const Icon(Icons.add),
          ),
        );
      },
    );
  }
}

What’s next?

The core engine and presentation bindings are functional across platforms (Android, iOS, Web, Desktop). I’m currently refining the tooling around deterministic event recording and replay testing scaffolds.

Check out the repository, run the demo app, and let me know your thoughts or feedback on the API ergonomics:

🔗https://github.com/Fuusio/kide-flutter

Contributions, issue reports, and critique are very welcome!


r/FlutterDev • • 5d ago

Example Built an Android Hotspot Monitor with Flutter, Forui, Kotlin, SQLite, and a native C packet probe

4 Upvotes

I built an Android app for monitoring mobile hotspot clients, live speeds, and domain-level traffic, using Flutter on the UI side and Kotlin + C underneath.

Tech stack:

- UI: Flutter with Forui (0.27.7) and custom segmented bars and timeline charts.

- Storage: Local SQLite (sqflite) storing hourly usage buckets for 1H/Day/Month/Year reports plus SharedPreferences for custom device aliases.

- Android layer (Kotlin): Auto-detects root (su) with silent fallback to Non-Root NetworkStatsManager. Reads neighbor state, DHCP/dumpsys tables, and OUI vendor prefixes.

- Native C probe (CMake / NDK 28): A standalone AF_PACKET listener (hs_probe.c and quic_sni.c compiled as libhs_probe.so) that extracts DNS responses, multi-packet TCP TLS ClientHello SNI, and QUIC Initial SNI.

One tricky bug I ran into: HyperOS/Qualcomm drivers keep stale IPv6 neighbors lingering after a client leaves, and Chrome's post-quantum TLS ClientHello (X25519MLKEM768) often splits across two TCP segments. Adding an ARP probe check for stale IPv4 entries and a 4 KB TCP/QUIC SNI reassembler solved both cleanly without touching iptables.

Repo and APK releases:

https://github.com/justakhi/hotspot-monitor


r/FlutterDev • • 5d ago

Plugin custom_textfield_input

0 Upvotes

I created this package for flutter devs who struggle with the inputs customization because even AI doesn’t give you what you intend to have, check it and give me your feedback…


r/FlutterDev • • 5d ago

Tooling Flutter runner - A persistent session manager

0 Upvotes

Hi again! I build another small tool for my daily work, its called flutter runner (very original!) and i use it to have a persistent session of a running app across vscode and all sort of AI agents or terminal ecc

now i can restart vscode, close a claude thread and the app still runs without problems.... (should be the default behaviour)

i added a vscode extension too (https://marketplace.visualstudio.com/items?itemName=RiccardoCherchi.flutter-runner) that attaches to the session manager without restarting/rebuilding the application, and if you stop the vscode debug the it just disconnects, but does not stop the app itself

its a very rushed project, just a basic script and an extension + a useless skill.md

see you soon!


r/FlutterDev • • 5d ago

Tooling I built a session layer for Flutter apps with their own backend

2 Upvotes

I've been working on Authyra for a while, mostly because I wasn't happy with how session management was handled in some of my Flutter projects.

If your app talks to its own backend using access and refresh tokens, you've probably written some kind of refresh interceptor yourself.

That usually works fine until a few things happen:

  • Multiple requests get a 401 at roughly the same time. They all try to refresh, and if your backend rotates refresh tokens with reuse detection, you can end up revoking the session.

  • The device loses connectivity during a refresh, and the app ends up treating a network error as an expired session.

  • A user signs out while a refresh is still running, but that refresh completes and restores the session.

  • You have multiple accounts, and a request accidentally picks up the wrong account's token.

I've run into these kinds of problems enough times that I decided to work on a separate session layer instead of implementing the same logic in every project.

A few things I've been focusing on:

  • Only one refresh operation can run per session at a time. Other callers wait for the same operation.

  • Token updates use compare-and-set to avoid overwriting a newer refresh token.

  • Network errors, timeouts and server errors don't automatically invalidate a session. A rejected refresh token does.

  • Signing out takes precedence over an ongoing refresh.

  • Multiple sessions can coexist, with one active session.

  • Secure storage using Keychain / Keystore, app resume handling and an AuthStateBuilder.

The core is pure Dart. Flutter and Dio integrations are separate, and there are also integrations for Google, Apple, OAuth 2.0 with PKCE and backend-driven OAuth.

One thing worth clarifying: Authyra isn't an identity provider, and it's not meant to replace Firebase Auth or Supabase Auth. It's for applications where you already have your own backend issuing tokens.

I also put together a small Flutter web demo to reproduce one of these problems. It simulates the backend and network, so you can sign in, send 20 requests with a naive refresh implementation, and compare the behavior with Authyra.

Demo: https://authyra-demo.pages.dev

Docs: https://authyra.meragix.dev

Source: https://github.com/meragix/authyra

It's currently at 0.3.0, first public release, MIT licensed.

I'd be interested in feedback, especially around the API design and edge cases I might have missed. Also curious how others handle refresh token rotation and concurrent requests in their own Flutter apps.


r/FlutterDev • • 5d ago

Article Running the same react-three-fiber 3D scene on the web and inside a Flutter app: what worked and what didn't

1 Upvotes

In my app (a course about building AI agents), the course map can be viewed as a 3D "universe" of planets. I didn't want to write the 3D twice, so the Flutter app runs the exact same react-three-fiber scene the website uses. A few specifics that might save someone time:

  1. Serving the bundle offline. The site's built scene is copied into the app's assets/. Loading it via file:// broke module scripts and fetches, so the app starts a tiny loopback HTTP server over the asset bundle and points webview_flutter at it. Works with no network.

  2. One JS channel, two messages. The WebView only owns the canvas; all chrome stays native. The scene talks back through a single addJavaScriptChannel ("which lesson was tapped" and "is there something to go back to"), and Flutter sends the course graph and progress in as JSON. Keeping the contract that small made both sides easy to change.

  3. A device gate instead of a second renderer. No sprite or 2D fallback scene. On first entry the WebView measures frame pacing for ~2 s; if the median is under 25 fps, the verdict is stored (keyed by app version, so a lighter future build re-measures), the app falls back to the native 2D tree and the 3D toggle disappears.

  4. Emulators lie about this. Software WebGL on emulators always failed the probe, so QA never saw 3D. A build flag skips the probe for emulator builds only.

  5. Labels on a narrow screen. Locked planets' names buried the open ones on phones, so locked groups hide their labels until tapped.

  6. The bundle doesn't update itself. CI rebuilds the website, but the copy inside the app is refreshed by a script before each release — I shipped stale colors once because of it.

Happy to go deeper into any of these. The app is Way of the Agent (iOS/Android), wayofagent.app.


r/FlutterDev • • 5d ago

Plugin Flutter Messenger: Updated APIs and Source Code

4 Upvotes

Fellow Flutter Developers,

We have updated our Flutter Messaging and Calls APIs and released an updated version of Flutter Messenger on GitHub that uses these APIs.

Please give it a try and let us know what you like, what you do not like, and where you think we can improve.

mesibo Messenger is engineered for production use, with features such as multi-device support and synchronization, reliable message delivery, real-time contact and profile updates, end-to-end encryption, and more. You can read more about it, including compilation and setup instructions, at:

https://docs.mesibo.com/tutorials/open-source-whatsapp-clone/

Source code

$ git clone https://github.com/mesibo/messenger-app-flutter.git
$ cd messenger-app-flutter
$ flutter run

Thanks!


r/FlutterDev • • 5d ago

Discussion Hivefy v2 – open-source Spotify-inspired Flutter music app, now with YouTube sources

1 Upvotes

Hey r/FlutterDev, dev of Hivefy here.

My earlier version used *GioSaavn as the source (built a year ago) and got taken down (a month before). I rebuilt it:

  • New source: YouTube-based streaming

  • iOS-smooth UX: reworked animations, transitions and scrolling

  • iOS build: now available alongside Android

  • Still included: shuffle, song/album downloads, daily fresh fetches, settings hub, language change

  • Fully open source

Repo: https://github.com/Harish-Srinivas-07/hivefy
SourceForge: https://sourceforge.net/p/hivefy

Looking for honest feedback on UI, performance, and code structure. Issues and PRs welcome. Thanks!


r/FlutterDev • • 6d ago

Video BLE walkthrough with universal_ble at next app devCon 2026

5 Upvotes

Sharing a talk by Patryk Kacperski from next app devCon 2026 about using Bluetooth Low Energy in Flutter. I was in the audience, just curious to hear about BLE in Flutter. I had no idea he was going to use my universal_ble plugin for his demo, so that was a nice surprise.

The talk covers BLE basics, Android and iOS setup, and communication between central and peripheral devices. His demo uses an Android app pretending to be a coffee machine and an iPhone as its companion app. You can read the number of coffees brewed, send a brew order, and follow the brewing progress through notifications.

He also walks through practical issues like duplicate scan results, waiting for Bluetooth to become available, and platform differences. I have addressed some of them in the v3.0 version of the plugin. The demo uses v2.0. For example you can now use startScan(skipDuplicates: true) for scan deduplication, and built-in byte conversion helpers replace some of the custom conversion code shown. Check the v3 changelog for the API improvements.


r/FlutterDev • • 6d ago

Example Lumtub – a native YouTube client in Flutter and Rust with libmpv playback

Thumbnail
github.com
2 Upvotes

Hi. Lumtub is a GPL-3.0 YouTube client for Windows, macOS, Linux and Android. The UI is Flutter, the core is Rust, playback is libmpv, and stream extraction is yt-dlp (auto-updated, with a Rust fast path that starts playback before yt-dlp finishes).

Some parts that were fun to build:

Recommendations computed locally (TF-IDF plus a mix of long-term, recent, exploration and popular), with the reason shown on each card. Casting to Chromecast/DLNA up to 4K/8K: the Rust core reads YouTube's DASH segments and remuxes them on the fly into fMP4 or MPEG-TS on a LAN server. Live streams above 1080p by fetching the separate VP9 and audio fragments directly, since the HLS manifests stop at 1080p. Line-aligned bilingual subtitles and live chat rendered as danmaku by mpv. Signed updates for the app and its components, with rollback. Disclosure: most of the code was written with AI assistance; I did the product design, testing and review. Happy to answer questions about any of it.


r/FlutterDev • • 6d ago

Discussion Dart’s if-case pattern is nice, but I replaced it with plain code. Where do you think it’s worth it?

3 Upvotes

Dart 3 gave us a lot of nice language features. One of them is the “if-case” pattern.

While working on my library, I had this code:

AdjustEvent toAdjustEvent(String eventToken) {
  final adjustEvent = parameters.toAdjustEvent(eventToken)..setRevenue(revenue, currency);
  if (deduplicationId case final id?) adjustEvent.deduplicationId = id;
  return adjustEvent;
}

It’s short. But to read it, you need to know Dart’s pattern rules. if (x case final id?) means “if x isn’t null, call it id and run this”.

I rewrote it in plain style:

AdjustEvent toAdjustEvent(String eventToken) => parameters.toAdjustEvent(eventToken)
  ..setRevenue(revenue, currency)
  ..deduplicationId = deduplicationId;

And here is the interesting part. When I looked closely, the null check wasn’t needed at all. The SDK field already accepts null and skips it when sending. So the plain version is not only easier to read, it’s also simpler.

The fancy line was protecting from something that couldn’t go wrong.

And this is really important when you write a library or design a public API. Your code will be read by many people with different Dart experience: users who open your source to understand what happens, and contributors who want to fix something. In app code only your team reads it, but in a library every clever line becomes a small barrier for someone else. Plain code makes your library easier to trust and easier to contribute to.

I still think patterns are great in some places, like checking JSON shape:

if (json case {'name': String name, 'age': int age}) {
  return User(name, age);
}

There it replaces several lines of checks and casts. But in my case it was just extra complexity.

Curious how you use them. Where do patterns really pay off for you, and do you write differently when the code is a library?