Dart: Dart is the programming language used to write Flutter applications. Dart provides static types, sound null safety and asynchronous APIs. Flutter uses Dart for both its widget code and application logic. Use a nullable type when a value may be absent, such as a profile name the user has yet to enter.
Definition source DeLaParra Services
Frequently asked questions about Dart
What should you keep in mind with Dart?
Handle missing values at the boundary where data enters your app. A forced null check can throw at runtime.
What does an example of Dart look like?
String displayName(String? name) => name ?? 'Guest';
Use when writing or reviewing any Dart or Flutter code for craft - naming, null safety, pattern matching, records, error handling idioms, dartdoc comments, logging, assertion style in tests, widget-level code quality (const, keys, dispose, BuildContext across an await), and analysis_options lint setup. Triggers on "clean this up", "is this idiomatic?", a code review of Dart, or a new file that sets a precedent others will copy.
Use when dealing with asynchrony in Flutter - async/await inside a Cubit, Streams and RxDart, Isolates for heavy work, cancelling an in-flight operation, or choosing between FutureBuilder and BlocBuilder. Triggers on UI freezes, jank, race conditions, or "setState after dispose".