Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
fluttertpc_get
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
jmsandamil
2020-08-21 09:31:38 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1fed9057bc29d1887ddfb8b148177b809d35070f
1fed9057
1 parent
223a7f37
Update README-es.md
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
README-es.md
README-es.md
View file @
1fed905
...
...
@@ -17,7 +17,7 @@ _Idiomas: Español (este archivo), [Inglés](README.md), [Portugués de Brasil](
-
[
Sobre GetX
](
#sobre-getx
)
-
[
Como contribuir
](
#como-contribuir
)
-
[
Instalando
](
#installing
)
-
[
Proyecto Counter en GetX
](
#proye
c
to-counter-no-getx
)
-
[
Proyecto Counter en GetX
](
#proyeto-counter-no-getx
)
-
[
Los tres pilares
](
#los-tres-pilares
)
-
[
Gestión del Estado
](
#gestión-del-estado
)
-
[
STATE_MANAGER Reactivo
](
#reactivo-state_manager
)
...
...
@@ -121,15 +121,15 @@ class Controller extends GetxController {
```
dart
class
Home
extends
StatelessWidget
{
// Cree una instancia de su clase usando Get.put
() para que esté disponible para todas las rutas "secundarias" allí.
// Cree una instancia de su clase usando Get.put() para que esté disponible para todas las rutas "secundarias" allí.
final
Controller
c
=
Get
.
put
(
Controller
());
@override
Widget
build
(
context
)
=>
Scaffold
(
// Utilice Obx
(() => para actualizar Text
() siempre que se cambie el recuento.
// Utilice Obx
(()=> para actualizar Text
() siempre que se cambie el recuento.
appBar:
AppBar
(
title:
Obx
(()
=>
Text
(
"Clicks: "
+
c
.
count
.
string
))),
// Reemplace el Navigator.push de 8 líneas por un simple Get.to
(). No necesitas contexto
// Reemplace el Navigator.push de 8 líneas por un simple Get.to(). No necesitas contexto
body:
Center
(
child:
RaisedButton
(
child:
Text
(
"Go to Other"
),
onPressed:
()
=>
Get
.
to
(
Other
()))),
floatingActionButton:
...
...
Please
register
or
login
to post a comment