This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
List<(String,String)> alumno = []; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
const MyApp({super.key}); | |
@override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() { | |
final numero = 10; | |
final lista = ["1","2","3"]; | |
print(saludo()); | |
print(retornoTupla()); | |
// Forma 1 | |
final data = retornoTupla(); | |
print(data.$1); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void main() { | |
// Crear una variable con el tipo de dato - tipo explícito | |
int age = 29; | |
print(age); | |
print(age.runtimeType); | |
// Variables que infieran el tipo | |
var nombre = "Richar"; | |
nombre = "Santiago"; | |
print(nombre); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() => runApp(const MyApp()); | |
class MyApp extends StatelessWidget { | |
const MyApp({super.key}); | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
final params = MessageListParams() | |
..isInclusive = false | |
..includeThreadInfo = true | |
..reverse = true | |
..includeReplies = true | |
..includeParentMessageText = true | |
..previousResultSize = 20; | |
final messages = await _currentChannel.getMessagesByTimestamp(ts, params); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Future<void> connectUser(UserModel user) async { | |
try { | |
await _sendBird.connect(user?.user?.email); | |
await _sendBird.updateCurrentUserInfo( | |
nickname: | |
"${user?.user?.firstName ?? ""} ${user?.user?.lastName ?? ""}", | |
fileInfo: FileInfo.fromUrl( | |
mimeType: "image/jpeg", | |
url: user?.picture ?? | |
"https://d3e978642pczga.cloudfront.net/images/chat/chat_avatar.png"), |