Closed PatrickLouys closed 6 years ago
Thanks for your thoughts, appreciated.
The Guard Clauses is interesting. I try to use the Clean Code approach of only having one return
point, but I do agree your link is more readable (even if I would add mandatory braces). Was there a particular file you felt could benefit from this approach?
As for the other items, I agree they are all good, but for now, I think even mentioning them might add too much complexity for beginners. It is long and complicated enough as it is! :-)
That said, there are two things that might help here:
Having thought a bit more about this, I think a paragraph could be added in the first chapter. Something along the lines of:
There are a number of design decisions that have been made in this code for the sake of simplifying concepts sufficiently for beginners. You might have heard of object orientation, a methodology for organising non-trivial projects. This would be good to use, but it was felt that there was enough to learn without adding this in too. For the same reason, a framework has been avoided, since it would add "magic" that hides how things actually work.
I've talked at some length about eschewing libraries, so perhaps it might fit in there.
The links here would be valuable for a more advanced audience, but as above, I don't think they fit here. Maybe if I do a follow-up tutorial one day. :smile_cat:
First of all, thanks for the effort you put into this. Looks like a really good tutorial for someone new to the language.
The only thing that worries me a little is what follows. Until you have a followup tutorial, it might be useful to link a few resources that point the readers in the right direction. Otherwise I feel it is rather likely that they will pick up bad habits without knowing so from one of the many bad tutorials out there.
A few topics that come to mind:
I did not give the tutorial an indepth read, so the suggestions might not be suited towards your target audience. Proceed with caution :)