brianegan / new_flutter_template

Test ideas for a new flutter template
140 stars 23 forks source link

Add MVC provider experiment #1

Closed filiph closed 3 years ago

filiph commented 3 years ago

See email. Please tear this apart.

brianegan commented 3 years ago

All options are on the table here in my eye! I think this would be really interesting to chat about with the community as well.

The only reason I stayed away from provider so far is that I've now taught 3 people in the past year who had learned provider before learning how to properly pass data and callback functions via Widget constructors.

Now, when I teach more beginner to intermediate folks, I tend to start with the very basics and then work up from there. However, that's really just my assumption based on recent events and a small sample size -- it'd be great to get more input on it :)

filiph commented 3 years ago

Thanks!

I want to reiterate the goal. Our goal is not to teach everything (or even much!) of Flutter development. Our goal is to provide a scaffold that bumps a Flutter developer over the "I don't know where to even put things" line. Everything else is out of scope. We can link to things (like docs, codelabs) or just mention things (e.g. "This template uses the MVC approach, which is explained in several books and thousands of online resources.").

To give a concrete example:

  1. I don't think someone who's at the "where do I put my widgets" stage is immediately worrying about i18n.
  2. If they do think about i18n, they will be glad to see a comment like /// Here's where you add your ARB files. but it's probably not a thing they'll do in the first few hours of writing an app.
  3. Our job is to put them on a path. We don't need to plot the whole route. As long as it's not too painful to refactor things a bit later, we've done our job. There's a difference between refactoring from "one huge stateful widget in main.dart", and from "a reasonable MVC-like structure".

These are just my assumptions. For example, I don't know: did the participants in the study talk about i18n? Or was that outside the scope of the discussion anyway?

I'm really glad we're doing this by writing code, btw. Thanks for putting all this together so quickly and well!

brianegan commented 3 years ago

I want to reiterate the goal. Our goal is not to teach everything (or even much!) of Flutter development

Absolutely! That's what I'm trying to figure out with these experiments: What is "just enough" structure that it doesn't require too much explanation, while still being structured enough to be helpful. We'll certainly need some input from the community and target audience to help find that balance :)

These are just my assumptions. For example, I don't know: did the participants in the study talk about i18n? Or was that outside the scope of the discussion anyway?

They did! In fact, the second participant follows the Flutter Kosltivec template which includes localization, and he specifically asked for localization to be included in the new Flutter template.