Skip to main content

20 posts tagged with "blog"

View All Tags

Flutter Conferences & Community Highlights 2025

· 14 min read
Majid Hajian
Developer Advocate

Cover

I love attending Flutter events. As someone deeply involved in the Flutter and DCM community, I take every opportunity to connect with fellow developers at conferences around the world.

We, at DCM team, decided to write our recap of the Flutter conferences that defined 2025. Even though we have not attended all of these events in person, still worth to mention them and add all of our highlights from those that we have attended personally.

Let's get started!

Best Flutter Features in 2025

· 24 min read
Majid Hajian
Developer Advocate

Cover

2025 was a big year for Flutter. Between February and November, the team shipped four stable releases (3.29 through 3.38), and each one brought meaningful improvements to how we build apps.

These weren't just minor updates. The team tackled real problems: shader jank on mobile, slow web development cycles, widget preview workflows, and AI coding assistance.

In this article, I'll walk you through the features that actually mattered in 2025. Some are stable and ready to use. Others are experimental but worth watching.

Best Dart Features to Highlight in 2025

· 17 min read
Majid Hajian
Developer Advocate

Cover

2025 was a milestone year for the Dart programming language. Between February and November, the Dart team shipped four stable releases (3.7 through 3.10), and each one quietly changed how thousands of us write code every day.

The cool part? These weren't just incremental tweaks. They were thoughtful additions that addressed real pain points, from reducing boilerplate in Flutter widget trees to making web development feel as smooth as mobile, to giving AI assistants actual knowledge of your project structure.

In this article, I'll walk you through the features that actually matter in 2025, with the context of why they were needed and what they mean for your workflow.

Here’s what we’ll cover in this article:

  • Dot Shorthands
  • Null-Aware Collection Elements
  • New Analyzer Plugin API
  • Dart & Flutter MCP Server
  • Build Hooks for Native Code Integration
  • Granular Deprecation Annotations
  • Documentation Imports with @docImport
  • Wildcard Variables with _
  • Other Noteworthy Improvements
  • Further Reading and References

Let's get started.

Flutter Hot Reload Isn't Enough (And Why Flutter Developers Need Widget Previews)

· 23 min read
Majid Hajian
Developer Advocate

Cover

I’ve been developing Flutter apps for years, and Flutter’s evolution never ceases to amaze me. One of the latest game-changers for UI design is the Flutter Widget Previewer, a tool introduced in Flutter 3.35 that lets you see your widgets render in real-time, without running a full app.

If you’ve ever used SwiftUI’s canvas or Jetpack Compose’s previews, this will feel familiar.

The first time I tried Widget Previewer, it clicked that this isn't just about faster hot reloads, it's about isolating UI like a Storybook for Flutter. Rather than navigating the app to see a state, you build previews that live beside your code, with every variation (light/dark, sizes, error states) ready to inspect.

In this post, we’ll explore what the Flutter Widget Previewer is, how to use it, what’s new in Flutter 3.38, and how it can supercharge your UI development, all while noting a few quirks to watch out for.

Let's get started

A Deeper Look at Dart's Dot Shorthands (and Their Hidden Complexity For Your Flutter Projects)

· 14 min read
Majid Hajian
Developer Advocate

Cover

I’ve been writing Flutter and Dart professionally for many years, and during that time, Dart has evolved in all kinds of exciting ways. We’ve gained sound null safety, pattern matching, sealed classes, the list keeps growing. But every once in a while, Dart introduces a feature that is deceptively small yet manages to reshape how we think and write code every day.

With Dart 3.10, released alongside Flutter 3.38 on November 12, 2025, we got one of those features: dot shorthands.

The first time I enabled the feature in a real codebase, my Flutter widget trees instantly felt lighter. The noise reduced. My eyes stopped tripping over repeated type names. And for a few minutes, I genuinely thought: "Why didn’t we have this earlier?"

But like every elegant piece of syntax, dot shorthands carry hidden complexity, especially when they escape the "safe" zones they were designed for. After reviewing, experimenting, and observing how teams naturally adopt (and misuse) them, I realized this is one of those cases where you need both excitement and caution.

This article is my deep dive into the feature; not just what dot shorthands are, but why they exist, how they work, where they might be tricky to use, and how you can get the best of them while avoiding the worst.

8 More Flutter Widgets You’re Probably Not Using (But Should Be)

· 38 min read
Majid Hajian
Developer Advocate

Cover

It never ceases to amaze me how Flutter continues to surprise developers with its depth and versatility. Even after years of working with this framework, there are still widgets hiding in plain sight that solve very specific problems elegantly.

I recently demonstrated a set of 10 widgets in a lightning talk at FlutterCon as a DCM advocate, where I showcased several niche but incredibly useful widgets. After the talk, I decided to turn it into an in-depth and more detailed blog post about these widgets. Like my previous article on 10 Flutter widgets you probably haven't heard of (But you should be using), I went into the source code to understand not just how to use these widgets, but also how they work under the hood.

Before we start, all examples and source code of this blog has been posted to this repo which was created for Navigating the Hard Parts of Testing in Flutter article.

Now, let's uncover these widgets together!

Getting Started with Flutter Lint and Static Analysis

· 16 min read
Majid Hajian
Developer Advocate

Cover

Static analysis in Flutter (and Dart) is the process of examining code for errors and style issues without running the app. It allows you to catch bugs and enforce best practices early, before executing a single line of code.

Adopting static analysis represents a fundamental "shift left" in the software development lifecycle (SDLC). This philosophy advocates for moving quality assurance and testing activities to the earliest possible stages of development.

Linting is a subset of static analysis that focuses on style and best-practice rules. Flutter’s analysis tool (often called the Dart/Flutter analyzer) uses a set of rules (called lints) to ensure your code follows the Dart style guide and Effective Dart recommendations.

This guide will walk you through setting up and mastering Flutter's linting and static analysis capabilities, from the basics to advanced configurations.

Let Your AI Assistant Tame Your Tech Debt (with Dart, Flutter and DCM MCP Servers)

· 24 min read
Majid Hajian
Developer Advocate

Cover

AI code generation is creating technical debt faster than ever before. Every AI-suggested shortcut, style inconsistency, and missed best practice taxes your team weeks later. Quality is no longer just a periodic check; it's a continuous, automated loop needed to keep a codebase sane

AI Assistants and Agents can orchestrate the quality loop end-to-end, which boosts velocity and more importantly consistency. The key is integration: when your assistant can call real, trusted tools through a clean interface, quality becomes a repeatable team habit.

That’s exactly what MCP enables and where DCM’s MCP server and the Dart/Flutter MCP server step in which give agents structured access to analyze, fix, and verify and an ultimate code quality gatekeeper.

In this article, we are going through how you can leverage DCM together with Dart & Flutter MCP server to make your AI assistant a trustworthy code agent. We will introduce reusable and sharable prompts that helps your team to leverage similar workable tasks and boost your productivity.

Navigating the Hard Parts of Testing in Flutter

· 29 min read
Majid Hajian
Developer Advocate

Cover

Testing is critical for building quality software and particularly in Flutter apps, especially as they grow and become more complex. Even experienced developers often see tricky scenarios and corner cases in Flutter unit and widget tests. I’ve certainly hit several edge cases myself. When I asked on Linkedin many developers responded with similar experiences.

In this article, you'll find best practices, real-world examples, and ready-to-use sample code addressing common challenges, like handling date/time bugs, platform differences, testing customPainters, asynchronous operations, or tricky plugins.

Our focus is specifically on vanilla Flutter unit and widget tests, not state management libraries such as Riverpod, BLoC or integration tests. I think those deserve articles of their own, maybe for later! One of our goals is also to know how to boost your test coverage, while 100% test coverage is controversial and especially regarding quality of tests for covering everything; it's sometimes a good indication of what and where to test.

Let's get started!

Practical Accessibility in Flutter (and Code You’ll Actually Use)

· 30 min read
Majid Hajian
Developer Advocate

Cover

I still remember the day a colleague turned on VoiceOver to try our Flutter app, then we found large parts of the UI were silent or confusing. No crashes or errors, just buttons with no labels, images announced only as "image," and custom widgets invisible to accessibility tools.

It's easy to forget about these during development, and they can silently exclude a group of our users and before you realize it, you might get a user complaint or a poor accessibility audit. Accessibility is crucial for inclusive apps, and thankfully Flutter’s latest updates are making it easier and faster to do the right thing.

In this post, I’ll share what I learned about building accessible Flutter apps with real examples, best practices, and leveraging Flutter 3.32’s new features to fix common pitfalls. We’ll explore mistakes like missing alt text on images or ignoring large font settings and how to fix them.

The Hidden Cost of Async Misuse in Flutter (And How to Fix It)

· 20 min read
Majid Hajian
Developer Advocate

Cover

I still remember the week I hunted a mysterious Flutter performance issue which had no crashes or error logs; just a sluggish app and somehow an increase usage of memory. Guess what? The issue was a missing await here, an unguarded setState() there.

These bugs don’t crash your app or shout errors; they silently cause memory leaks, UI glitches, and race conditions that surface only after extended use. Problem is that when you spot these behaviors or degraded performance, the damage is done.

In this post, I’ll share what I learned about async misuse’s hidden costs in Flutter, with real examples and fixes. We’ll explore common pitfalls (some of which I’ve embarrassingly written myself), see their sneaky production impacts, and how to use tools like DCM to catch them early.

15 Common Mistakes in Flutter and Dart Development (and How to Avoid Them)

· 41 min read
Majid Hajian
Developer Advocate

Cover

As Flutter projects grow, mistakes that didn’t matter early on can start affecting performance, stability, and maintainability. Some are easy to miss. Others are misunderstood or handled inconsistently across teams.

In this article, I am going to focus on mistakes that are common in Flutter and Dart apps, especially in larger codebases or long-running apps which I have often seen in the last 6-7 years of being in the field. They range from memory leaks and rebuild issues to state misuse, testing gaps, and architectural problems. All of them are avoidable. Most can be detected with static analysis such as DCM. Some require deeper architectural decisions.

Let's get started and see which of these issues are familiar to you and which of them you already have done! I bet you can resonate with many of the following issues.

10 Lesser-Known Dart and Flutter Functionalities You Should Start Using

· 44 min read
Majid Hajian
Developer Advocate

Cover

I started writing Dart code in 2019, and since then, I've been learning something new every day. It’s fascinating to see what this framework and language have to offer.

In this article, I want to share some of those hidden gems I’ve discovered—lesser-known functionalities that can simplify your development process and add a unique touch to your apps. Moreover, we will go deeper into the implementation and explore how they are implemented to learn more about the patterns.

Let’s uncover some of these functions and methods together!

Step by Step Guide to Integrate DCM Into A Flutter & Dart Open Source Package: dart_mappable

· 17 min read
Majid Hajian
Developer Advocate

Cover

I recently had the pleasure of collaborating with Kilian, the developer behind several Dart and Flutter open-source packages, including the popular "dart_mappable". "dart_mappable" is a package that simplifies JSON serialization, data classes, and supports powerful features like advanced inheritance and generics.

In this post, I'll walk you through how we integrated DCM into "dart_mappable" and show you how you can select rules, create baseline and start fixing issues quickly.

10 Flutter Widgets Probably Haven’t Heard Of (But Should Be Using!)

· 34 min read
Majid Hajian
Developer Advocate

Cover

It’s been over 6 years since I started developing with Flutter and Dart, and yet I still come across features or widgets that I didn’t know existed. It’s fascinating how a framework you work with daily can still surprise you with its depth and versatility.

In this article, I want to share some of those hidden gems I’ve discovered lesser-known widgets and functionalities that can simplify your development process and add a unique touch to your apps. Moreover, we will go deeper into the implementation and explore how they are implemented to learn more about the patterns.

Let’s uncover some of these widgets together!