Flutter · colveor_ui

Configuration

Extend VoConfig once and pass it to ColveorApp. The package reads it through voConfigProvider.

VoConfig

app_config.dart
Dart
import 'package:colveor_ui/config.dart';

class AppConfig extends VoConfig {
  @override
  String get appName => 'My App';

  @override
  VoRoutingConfig get routing =>
      const VoRoutingConfig(initialLocation: AppPaths.splash);

  @override
  String get initialCountryCode => 'GB';

  @override
  List<String> get favoriteCountries => ['GB', 'NG', 'US'];
}
NameDescription
appNameRequired. Human-readable app name.
routingRequired. A VoRoutingConfig — see Routing.
environmentDefault Environment.current.
initialCountryCodeDefault country for the phone input. Default 'NG'.
favoriteCountriesCountries listed first in the country picker. Default ['NG'].
feedbackTitles and icons used by VoFeedbackView. Default DefaultFeedbackConfig().

With the full package, extend VoConfig from package:colveor/config.dart instead — it adds API and Firebase settings.

Environment

Environment is development or production. Environment.current reads the FLAVOR build define and defaults to development:

Bash
flutter build apk --dart-define=FLAVOR=production