Flutter in Practice - E07: Automatic JSON Serialization

preview_player
Показать описание
Flutter in Practice is a free programming course that teaches how to write a mobile application using Flutter framework and Dart programming language. Instead of teaching concepts and ideas in both Flutter and Dart, this course showcases a process of building an actual, mobile application.
In this tutorial, we will create an email client that exclusively supports JMAP protocol.

#flutterinpractice #flutter #dart #tutorial #guide
Рекомендации по теме
Комментарии
Автор

hi. the [ part 'Message.g.dart'; ] needs to be [ part 'message.g.dart'; ] in lowercase naming convention. I found about that by trial and error method. Thx

Автор

Finally understood this 😌.Was stuck at this from 2days but you finally saved me n my code😄🙏🏻

rutviktak
Автор

Thank you, what is this theme? I like it.

ahmed_alharthi
Автор

Hi ty for videos, got a question: I hav map of 2 maps, the 2nd map inside consists of list of map I need how do u approach this.. use jso serialization or built values from dart????

pradeep
Автор

To anyone wondering how to create toJson at the same time after using json_annotation, add getter to your class like this:
Map<String, String> get toJson => _$ClassNameToJson(this);
where _$ClassNameToJson is function generated in class_name.g.dart file.

Kolano
Автор

At 0:31 line 19 you show the return value of the loadMessageList function declaration to be a Future. Shouldn't this be void? loadMessageList doesn't return anything. It just calls setState() and sets messages = _messages. Not picking, just trying to understand. Great videos!

sreid
Автор

Hello. Ho do I go about using this "part of" and "part". Its never works fine here.

manoeltsf
Автор

you may need to run flutter pub get before the build_runner command

samarioantonio
Автор

Thank you so much for your great effort <3

sunaarun
Автор

I couldn't the error disappear part 'Message.g.dart'; please help me

swalihvmbazar
Автор

I needed to migrate the project to AndroidX for the build_runner step to work

mcwongatron
Автор

when i try to add the command,
this is what I get >> bash: flutter: command not found

moaazElneshawy
Автор

may be with a nested json
with double dimensional array
like data grouped by date
and dispaying with sticky headers

also to map function and then to list is been very confusing
if possible pl adress those issues
i hope i am not asking too much

mrpakravian
Автор

Your IDE looks attractive (Font color), Please share your VS extensions with us.

JayeshLathiya
Автор

cant create the file '...g.dart. the vscode doesnt recognize the flutter name in the cmdlet

DJSacudimeelcarancho
Автор

thanks vry much again
plz put some more light on it
if you could

mrpakravian
Автор

for someone who still can not generate "message.g.dart".
the file name need to be the same.
For example:
the file of Message model class is message_model.dart
and you wrote: part 'message.g.dart'; .It will NOT WORK.
you need to change to : part 'message_model.g.dart';
and then run: flutter pub run build_runner build
and Voila, working :o)
So depend on the name of model class dart file name. Be careful :o)

LuminousAsianBeauties
Автор

Dart data class Sniped for va Code do the same

tetrastrider
join shbcf.ru