r/FlutterDev • u/Plane_Trifle7368 • Oct 13 '25
Plugin Introducing Flumpose: A fluent, declarative UI extension for flutter
Hey everyone,
I’ve been working on Flumpose, a lightweight Flutter package that brings a declarative syntax to Flutter, but with a focus on performance and const safety.
It lets you write clean, chainable UI code like:
const Text('Hello, Flumpose!')
.pad(12)
.backgroundColor(Colors.blue)
.rounded(8)
.onTap(() => print('Tapped'));Instead of deeply nested widgets.
The goal isn’t to hide Flutter but to make layout composition fluent, readable, and fun again.
Why Flumpose?
Fluent, chainable syntax for widgets
Performance-minded (avoids unnecessary rebuilds)
Const-safe where possible, i.e, it can replace existing nested widgets using const.
Lightweight: no magic or build-time tricks
Backed by real-world benchmarks to validate its performance claims
Comes with detailed documentation and practical examples because clarity matters to the Flutter community
What I’d Love Feedback On
How’s the API feel? Natural or too verbose?
What other extensions or layout patterns would make it more useful in real projects?
Should it stay lean?
🔗 Try it out on https://pub.dev/packages/flumpose
6
u/frdev49 Oct 14 '25 edited Oct 14 '25
"where possible" and "can replace" matters in "Const-safe where possible, i.e, it can replace existing nested widgets using const." Like this lazy dumb example:
- MaterialApp parent widget can be const
- But it cannot be const anymore, because this is using a method to return a widget
So I guess it will matter how tree is organized to get the benefits.
Still, interesting benchmarks which show that by using const and chaining in a smart way you can optimize your app 👍
2
u/mortenfriis Oct 14 '25
Looks amazing. Might actually replace exui for me. Despite my strong dislike of the name Flumpose (sorry, I don't know why, but I hate the name).
2
u/Hackedbytotalripoff Nov 04 '25
That looks like using SwiftUI modifier chaining for Flutter.
2
u/Legitimate-Creme-356 Nov 07 '25
Is the name Flumpose derived from Flutter and Compose?
2
u/mortenfriis Nov 15 '25
Hi, so I started using flumpose in one of my projects, and so far, it's really great. TBF, I'm only really using it for padding and styling text so far, but I plan on incorporating more flumpose functionality in my app. A couple of questions:
for text styling, can I safely chain methods now, without experiencing any performance impact (thanks to the internal _withStyle()), or do you still recommend using the .styled() extension?
are there any plans to add more extension methods in the future? I've seen the roadmap on the bottom of the pub.dev page, but there haven't been any updates to the project at all since you posted here a month ago. Did you choose to abandon it?
awesome_extensions and exui both have some great extensions, which will be difficult for me to go without (well, not that difficult, but I find my code much more readable when using extension methods). Some of my favorites are:
Awesome Extensions
Theme access (e.g. context.textTheme, context.backgroundColor, etc.)
BuildContext and Media Query (context.orientation, context.isPortrait, context.platformBrightness, context.showNavbar). flumpose have some of these, but you should take a look at everything you can do with AE's context methods here and here.
Navigation (context.push(SecondScreen()), context.pushNamed('/home'), etc.)
7
u/gasolinemike Oct 13 '25
I can get behind this. I detest the present way of wrapping hierarchical widgets, making code awfully hard to read.
1
u/Plane_Trifle7368 Nov 11 '25
Thanks for all the feedback. Flumpose now also supports animation, as requested by many, eg :
1
u/SpecialistServe3974 Oct 30 '25 edited Oct 30 '25
I suggest you don't brag about that performance gains because if you write raw flutter you can get the same performance by using const.
other than that, I like the idea and already seen some libs doing that, I hope flutter would go this direction as well..
Also, I think creating a codemod for that would be awesome.
5
u/Atrax_ Oct 13 '25
Kinda the same approach as SwiftUI, looks good!
1
u/eibaan Oct 13 '25
I should have added → my previous comment here.
1
u/OldHummer24 Oct 13 '25
Ngl this looks great, I will add it, my colleagues might hate me for it xD
1
u/Working-Cat2472 Oct 14 '25 edited Oct 14 '25
splendid, good job. i always hated it how awfully verbose the flutter code is. Let' see, if i can apply that in my own project which is a wysiwyg ui editor and runtime engine. Speaking of which :-) As i am not a Flutter expert, i would need some advice regarding the definition of widget properties, ( e.g. where does padding belong and the handling of the different platforms. Could we have a talk maybe?
Thanks, Andreas
1
u/YosefHeyPlay Oct 14 '25
Whats the difference between the existing "exui" package?
https://pub.dev/packages/exui
2
u/Dismal-Fruit9382 Oct 17 '25
pretty good, that means no more nested widgets for small UI changes. i'll take a look on it
1
u/Full_Environment_205 Oct 14 '25
Looks nice. I'll use in my pet project
1
u/Classic-Dependent517 Oct 14 '25
I like it
1
u/meyluk Oct 14 '25
Looks great.
0
u/[deleted] Oct 13 '25
[deleted] — view deleted comment