You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Override files take precedence over the base file. Register all env files as assets in `pubspec.yaml`.
239
239
240
+
## Remote configuration
241
+
242
+
If you want to manage environment configs remotely and load them by config ID at runtime, see the companion package [flutter_dotenv_remote](https://pub.dev/packages/flutter_dotenv_remote). It also supports using the last successful config as a local fallback.
243
+
244
+
```dart
245
+
await dotenv.loadRemote(
246
+
configId: 'your-config-id',
247
+
useCacheOnFailure: true,
248
+
);
249
+
```
250
+
240
251
## Multiple instances
241
252
242
253
The package exports a pre-created singleton `dotenv` for the common case. You can also create separate instances for different configurations — each instance maintains its own independent state:
0 commit comments