support -D dart environment variables
diff --git a/frontend_server_client/lib/src/frontend_server_client.dart b/frontend_server_client/lib/src/frontend_server_client.dart
index 3a62274..3ab906d 100644
--- a/frontend_server_client/lib/src/frontend_server_client.dart
+++ b/frontend_server_client/lib/src/frontend_server_client.dart
@@ -68,6 +68,8 @@
     bool printIncrementalDependencies = true,
     List<String> additionalSources = const [],
     String? nativeAssets,
+    // -D=key=value arguments for dart environment variables
+    Map<String, String>? dartDefines,
   }) async {
     final commonArguments = <String>[
       '--sdk-root',
@@ -97,6 +99,9 @@
         '--native-assets',
         nativeAssets,
       ],
+      if (dartDefines != null) ...[
+        for (var entry in dartDefines.entries) '-D=${entry.key}=${entry.value}',
+      ],
     ];
     late final Process feServer;
     if (frontendServerPath != null) {