A Flutter Without SetState

Andrew Zuo
CodeX
Published in
4 min readFeb 21, 2022

--

UI is a function of state

So I’ve been thinking about setState() in Flutter. This is perhaps the most important method in Flutter. It’s the method that refreshes your widget and makes it so you can actually see the changes.

But here’s the thing: you don’t actually need setState(). Well, you’ll always need to call setState() or a related method somewhere but you don’t actually have to call it directly. You can use state management to do it for…

--

--

Andrew Zuo
CodeX

Andrew Zuo is an independent app developer and blogger. He mostly blogs about interesting controversies around the internet and programming topics.