MP
Size: a a a
MP
EE
SS
ВК
SS
if (const bool.fromEnvironment('dart.vm.product')) {
// release mode
} else {
BlocSupervisor.delegate = SimpleBlocDelegate();
}
Ю
EE
EE
SS
flutter build --flavor development
These are mapped to android productFlavors and iOS schema.
EE
flutter build --flavor development
These are mapped to android productFlavors and iOS schema.
ВК
EE
if (const bool.fromEnvironment('dart.vm.product')) {
// release mode
} else {
BlocSupervisor.delegate = SimpleBlocDelegate();
}
class Configuration {
static const isStore = false;
static final Configuration _instance = Configuration._();
bool isDevelop = true;
factory Configuration() => _instance;
Configuration._();
String get host {
if (isStore) {
return "http://0.0.0.0";
}
if (isDevelop) {
return "http://1.1.1.1";
} else {
return "http://0.0.0.0";
}
}
}
КМ
EE
isStore
как нибудь сетапить при сборке для qa и для стора, может через флауерсDO
class Configuration {
static const isStore = false;
static final Configuration _instance = Configuration._();
bool isDevelop = true;
factory Configuration() => _instance;
Configuration._();
String get host {
if (isStore) {
return "http://0.0.0.0";
}
if (isDevelop) {
return "http://1.1.1.1";
} else {
return "http://0.0.0.0";
}
}
}
EE
ВК
DO
ВК