feat(binding): add deprecated proxy async methods for backward compatibility and highlight transition to modern API

This commit is contained in:
Sergey Penkovsky
2025-07-31 14:26:59 +03:00
parent 9f0a8a84aa
commit a74c34876d

View File

@@ -91,6 +91,21 @@ class Binding<T> {
return this;
}
@Deprecated('Use toInstance instead of toInstanceAsync')
Binding<T> toInstanceAsync(Instance<T> value) {
return this.toInstance(value);
}
@Deprecated('Use toProvide instead of toProvideAsync')
Binding<T> toProvideAsync(Provider<T> value) {
return this.toProvide(value);
}
@Deprecated('Use toProvideWithParams instead of toProvideAsyncWithParams')
Binding<T> toProvideAsyncWithParams(ProviderWithParams<T> value) {
return this.toProvideWithParams(value);
}
/// RU: Инициализация экземляпяра  как сингелтон [value].
/// ENG: Initialization instance as a singelton [value].
///