-
Notifications
You must be signed in to change notification settings - Fork 13.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code comments #385
Comments
I saw this article yesterday: Yes, your code does need comments. I think it's a good guideline, but would go even one step further since this is not a regular application, but is intended for learning. So too much commenting is pretty hard to achieve. |
Do we want to go down the path of docco compatible comments or something similar so folks have more literate code or is it enough to ask that they just comment more thoroughly? Let's find the app in our collection that is exemplary comments wise. Think the Ember guys were going to try doing this for theirs. |
I've just been using ToDoMVC in order to familiarise myself with Dojo. In terms of code-level comments, this implementation is rather good. However, what I personally find very useful, in fact more useful, is something which explains the overall structure of the application. As an example, looking at the Dojo code: https://github.com/tastejs/todomvc/tree/gh-pages/architecture-examples/dojo/js/todo What's the purpose of the code within the Where is the code that implements the persistence requirement? Has the author had to create their own UI widgets in order to meet the spec? I like to be able to quickly 'home in' on the interesting bits of code. The code that implements the actual to-do list logic! Code comments help you understand the purpose of each function, and perhaps the responsibilities of a specific file. However, I find myself having to navigate through, and read, a number of files before I can build up a picture of the overall application structure. I would like to see something that describes the folder structure and the responsibilities of the various files for each framework implementation. |
I think todomvc should take inspiration from this type of source commenting: http://tutorialzine.com/2013/08/learn-angularjs-5-examples/ +1 for more comments. |
Since TodoMVC is for learning, we should make sure all our implementations, both new and existing ones are fully commented.
Going to update the app spec, just need to make sure we ask for the right kind of comments. I've seen a lot of different commenting styles and only liked some. IMO commenting should explain the why (and sometimes the how), code should explain the how and what.
Anyone have a good resource we can link to about proper code commenting?
The text was updated successfully, but these errors were encountered: