From 01a9ea3aa1d6ad8a3bef2c5894a227f55a69253e Mon Sep 17 00:00:00 2001 From: Emad Rad Date: Sat, 18 Nov 2023 23:28:45 +0330 Subject: [PATCH] doc: cleanup re-order supported languages alphabetically and fixed some MD warnings --- README.md | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index be419c9a9..219d8c78a 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png) +![getx-header](https://raw.githubusercontent.com/jonataslaw/getx-community/master/get.png) [![pub package](https://img.shields.io/pub/v/get.svg?label=get&color=blue)](https://pub.dev/packages/get) [![popularity](https://img.shields.io/pub/popularity/get?logo=dart)](https://pub.dev/packages/get/score) @@ -14,30 +14,28 @@ Buy Me A Coffee -![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/getx.png) - +![getx](https://raw.githubusercontent.com/jonataslaw/getx-community/master/getx.png)
**Languages:** - +[![Bangla](https://img.shields.io/badge/Language-Bangla-blueviolet?style=for-the-badge)](README-bn.md) +[![Chinese](https://img.shields.io/badge/Language-Chinese-blueviolet?style=for-the-badge)](README.zh-cn.md) [![English](https://img.shields.io/badge/Language-English-blueviolet?style=for-the-badge)](README.md) -[![Vietnamese](https://img.shields.io/badge/Language-Vietnamese-blueviolet?style=for-the-badge)](README-vi.md) +[![Farsi](https://img.shields.io/badge/Language-Farsi-blueviolet?style=for-the-badge)](README.fa-IR.md) +[![French](https://img.shields.io/badge/Language-French-blueviolet?style=for-the-badge)](README-fr.md) +[![Hindi](https://img.shields.io/badge/Language-Hindi-blueviolet?style=for-the-badge)](README-hi.md) [![Indonesian](https://img.shields.io/badge/Language-Indonesian-blueviolet?style=for-the-badge)](README.id-ID.md) -[![Urdu](https://img.shields.io/badge/Language-Urdu-blueviolet?style=for-the-badge)](README.ur-PK.md) -[![Chinese](https://img.shields.io/badge/Language-Chinese-blueviolet?style=for-the-badge)](README.zh-cn.md) -[![Portuguese](https://img.shields.io/badge/Language-Portuguese-blueviolet?style=for-the-badge)](README.pt-br.md) -[![Spanish](https://img.shields.io/badge/Language-Spanish-blueviolet?style=for-the-badge)](README-es.md) -[![Russian](https://img.shields.io/badge/Language-Russian-blueviolet?style=for-the-badge)](README.ru.md) -[![Polish](https://img.shields.io/badge/Language-Polish-blueviolet?style=for-the-badge)](README.pl.md) [![Korean](https://img.shields.io/badge/Language-Korean-blueviolet?style=for-the-badge)](README.ko-kr.md) -[![French](https://img.shields.io/badge/Language-French-blueviolet?style=for-the-badge)](README-fr.md) [![Japanese](https://img.shields.io/badge/Language-Japanese-blueviolet?style=for-the-badge)](README.ja-JP.md) -[![Hindi](https://img.shields.io/badge/Language-Hindi-blueviolet?style=for-the-badge)](README-hi.md) -[![Bangla](https://img.shields.io/badge/Language-Bangla-blueviolet?style=for-the-badge)](README-bn.md) - - +[![Polish](https://img.shields.io/badge/Language-Polish-blueviolet?style=for-the-badge)](README.pl.md) +[![Portuguese](https://img.shields.io/badge/Language-Portuguese-blueviolet?style=for-the-badge)](README.pt-br.md) +[![Russian](https://img.shields.io/badge/Language-Russian-blueviolet?style=for-the-badge)](README.ru.md) +[![Spanish](https://img.shields.io/badge/Language-Spanish-blueviolet?style=for-the-badge)](README-es.md) +[![Urdu](https://img.shields.io/badge/Language-Urdu-blueviolet?style=for-the-badge)](README.ur-PK.md) +[![Vietnamese](https://img.shields.io/badge/Language-Vietnamese-blueviolet?style=for-the-badge)](README-vi.md) +
- [About Get](#about-get) @@ -194,7 +192,7 @@ class Other extends StatelessWidget { Result: -![](https://raw.githubusercontent.com/jonataslaw/getx-community/master/counter-app-gif.gif) +![counter-app](https://raw.githubusercontent.com/jonataslaw/getx-community/master/counter-app-gif.gif) This is a simple project but it already makes clear how powerful Get is. As your project grows, this difference will become more significant. @@ -939,6 +937,7 @@ user.update((value){ print( user ); ``` + ## StateMixin Another way to handle your `UI` state is use the `StateMixin` . @@ -975,7 +974,7 @@ class OtherClass extends GetView { body: controller.obx( (state)=>Text(state.name), - + // here you can put your custom loading indicator, but // by default would be Center(child:CircularProgressIndicator()) onLoading: CustomLoadingIndicator(), @@ -1102,7 +1101,6 @@ The only way to actually delete a `GetxService`, is with `Get.reset()` which is "Hot Reboot" of your app. So remember, if you need absolute persistence of a class instance during the lifetime of your app, use `GetxService`. - ### Tests You can test your controllers like any other class, including their lifecycles: @@ -1157,6 +1155,7 @@ Test the state of the reactive variable "name" across all of its lifecycles''', #### Tips ##### Mockito or mocktail + If you need to mock your GetxController/GetxService, you should extend GetxController, and mixin it with Mock, that way ```dart @@ -1164,11 +1163,12 @@ class NotificationServiceMock extends GetxService with Mock implements Notificat ``` ##### Using Get.reset() + If you are testing widgets, or test groups, use Get.reset at the end of your test or in tearDown to reset all settings from your previous test. -##### Get.testMode -if you are using your navigation in your controllers, use `Get.testMode = true` at the beginning of your main. +##### Get.testMode +if you are using your navigation in your controllers, use `Get.testMode = true` at the beginning of your main. # Breaking changes from 2.0