These changes make the the text clearer to me. I did not want to change the voice of the text, but I tried to clear out some verbosity and improve consistency. I did my best not to interfere with the logic of the prose.
This document seems written to stand on its own, so I recommend the following changes:
- a general explanation of the args param as in `controller: function(args) {` and `view: function(ctrl, args) { ...` (when first used, well before the signature)
- a specific explanation of {data: args} in m.request() (mithril.request.md could use the same treatment)
- an explanation of the extras param as in `controller: function(args, extras) {` and `view: function(ctrl, args, extras) { ...`
- the term *rollback* should be explained or replaced
- caveat #3/#4: Should *root element* be changed to *top-most element* so as not to be confused with the element the component is mounted on ?
- in testing, explain why the first param to view is `null`
I hope you can find some of this useful.
- The term *rollback* should be explained or replaced
- caveat #3/#4: Should *root element* be changed to *top-most element* so as not to be confused with the element the component is mounted on ?
These changes make the the text clearer to me. I did not want to change the voice of the text, but I tried to clear out some verbosity and improve consistency. I did my best not to interfere with the logic of the prose.
This document seems written to stand on its own, so I recommend the following additions:
- a general explanation of the args param as in `controller: function(args) {` and `view: function(ctrl, args) { ...`
- a specific explanation of how {data: args} in m.request() becomes url parameters (mithril.request.md could use the same treatment)
- an explanation of the extras param as in `controller: function(args, extras) {` and `view: function(ctrl, args, extras) { ...`
Signature document for "background" option contains almost same meaning sentences. First one has more information, and I think separated warning message is easy to read (difficult to pass through), I changed like this:
* Remove a simpler sentence.
* Move a detailed sentence to the bottom where simpler sentence was originally.