Jonatas

added Russian language to readme-md

![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png)
*Idiomas: Español (este archivo), [Lengua china](README.zh-cn.md), [Inglés](README.md), [Portugués de Brasil](README.pt-br.md), [Polaco](README.pl.md).*
*Idiomas: Español (este archivo), [Lengua china](README.zh-cn.md), [Inglés](README.md), [Portugués de Brasil](README.pt-br.md), [Russo](README-ru.md), [Polaco](README.pl.md).*
[![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get)
![building](https://github.com/jonataslaw/get/workflows/build/badge.svg)
... ...
![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png)
_Languages: English (this file), [Chinese](README.zh-cn.md), [Brazilian Portuguese](README.pt-br.md), [Spanish](README-es.md),[Polish](README.pl.md)._
_Languages: English (this file), [Chinese](README.zh-cn.md), [Brazilian Portuguese](README.pt-br.md), [Spanish](README-es.md), [Russian](README-ru.md), [Polish](README.pl.md)._
[![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get)
![building](https://github.com/jonataslaw/get/workflows/build/badge.svg)
... ...
![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png)
*Languages: [English](README.md), [Język chiński](README.zh-cn.md), [Brazilian Portuguese](README.pt-br.md), [Spanish](README-es.md), Polish (Jesteś tu).*
*Languages: [English](README.md), [Język chiński](README.zh-cn.md), [Brazilian Portuguese](README.pt-br.md), [Spanish](README-es.md), [Russian](README-ru.md), Polish (Jesteś tu).*
[![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get)
![building](https://github.com/jonataslaw/get/workflows/build/badge.svg)
... ...
![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png)
*Idiomas: [Inglês](README.md), [Língua chinesa](README.zh-cn.md), Português Brasileiro (este arquivo), [Espanhol](README-es.md), [Polaco](README.pl.md).*
*Idiomas: [Inglês](README.md), [Chinês](README.zh-cn.md), Português Brasileiro (este arquivo), [Espanhol](README-es.md), [Russo](README-ru.md), [Polonês](README.pl.md).*
[![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get)
![building](https://github.com/jonataslaw/get/workflows/build/badge.svg)
... ...
![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png)
_语言: 中文, [英文](README.md), [巴西葡萄牙语](README.pt-br.md), [西班牙语](README-es.md), [波兰语](README.pl.md)_
_语言: 中文, [英文](README.md), [巴西葡萄牙语](README.pt-br.md), [俄语](README-ru.md), [西班牙语](README-es.md), [波兰语](README.pl.md)_
[![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get)
![building](https://github.com/jonataslaw/get/workflows/build/badge.svg)
... ...
library rx_stream;
import 'dart:async';
import 'package:flutter/scheduler.dart';
import '../rx_typedefs/rx_typedefs.dart';
part 'get_stream.dart';
... ...
... ... @@ -122,15 +122,19 @@ abstract class GetNotifier<T> extends Value<T> with GetLifeCycleBase {
}
extension StateExt<T> on StateMixin<T> {
Widget obx(NotifierBuilder<T> widget, {Widget Function(String error) onError, Widget onLoading}) {
Widget obx(
NotifierBuilder<T> widget, {
Widget Function(String error) onError,
Widget onLoading,
}) {
assert(widget != null);
return SimpleBuilder(builder: (_) {
if (status.isLoading) {
return onLoading ?? CircularProgressIndicator();
return onLoading ?? Center(child: CircularProgressIndicator());
} else if (status.isError) {
return onError != null
? onError(status.errorMessage)
: Text('A error occured: ${status.errorMessage}');
: Center(child: Text('A error occured: ${status.errorMessage}'));
} else {
return widget(value);
}
... ...