Shared user guide #677
Shared user guide #677
Comments
|
Sorry, still have to look into it, but that will at earliest be next week.
Op wo 29 mei 2019 23:29 schreef Daniel K. <notifications@github.com>:
… @mweststrate <https://github.com/mweststrate> With 6.0 out now (
|
|
Only glanced over it, but some feedback points:
Some of the example are a bit convoluted, for example on the introduction page: Creating an inline component is quite a bad idea, as it kills the reconciler, and at least a bad example to set: The localStore's addTodo is expressed in terms of the ref. If instead the text to be added would be passed in, there would be a clear separation between the logic and the internal stuff of the component, and the entire initializer could actually be extracted out of the component. The example uses So I think there could be a bit simpler example to introduce the whole concept :). Random idea: https://codesandbox.io/s/evwj5. Yes, it is more contrived, but it will have less noise so it is easier to see what it is all about All IMHO of course, awesome that you are taking the effort! The beta notice on the libraries page can be removed. Sections I really liked: |
|
Thanks for the feedback!
The main motivation was to minimize duplicate information in mobx-react a mobx-react-lite readme. I wanted to consolidate that so people can really come to one place no matter what lib they are using. I am sure it still needs improvements, but without actual feedback, it's harder for me to see what needs to be changed. Also, the mobx.js.org could remove mention of React (doesn't really fit there).
I wonder where I am actually dismissing class components as something less? It definitely wasn't the intention. Personally, I haven't been using classes even before hooks unless I really had to. I would of course love if people would just abandon classes, so I am sometimes biased there, but I am trying not to be. I think I want to figure out some nice way how can user switch the mode to either hooks or classes and see that page for that respective approach. I don't want to mingle both in a single document, that would be way too confusing. Besides, when classes will be really gone, I want to just turn off the switch without updating those docs and removing all mentions manually.
Defining inline function
Well, the intention was to show that actions on the store are auto bound so they can be used directly as a callback prop without extra function wrapping or binding. Semantically, it definitely makes sense what you are suggesting.
That's the slight problem of Docz. All those live examples are not linked to that code shown below them. It's necessary to synchronize it manually. I need to figure some other way to tackle that more gracefully.
Right, the timer example is nice, I will use that :)
Will do, although it clearly states it applied in May 2019. |
|
[offtopic]
Don't agree on that one; first of all, mobx-react is the primary use case of mobx. Secondly, without concrete application in the forms of mobx-react, the mobx documentation would be very abstract in general, and describing artificial usecases and problems most people don't have. I do agree on the consolidation though. I would be perfectly fine by making an separate top level section on mobx.js.org, and emptying and forwarding the readme of mobx-react and mobx-react-lite there.
I see. I think having separate pages, describing the same use cases would be very clear as well. Than we can just cross link and people can compare if they want, and also we can recommend the hooks version on the class page.
Yeah, the problem is in either case, that it will re-render the full list on every change. Smaller components perform much better (as it explained later in the docs). But yeah, an simpler example avoids this problem altogether and we need to to introduce less concepts at once (I mean, people shouldn't need to think about performance in the first example, but not unconsciously be learning a bad practice either)
Good point! Missed that. I think the timer has this case as well. |
|
Closing as combined docs are WIP on the mobx 6 branch: https://deploy-preview-2327--mobx-docs.netlify.app/react/react-integration.html |

Formed in 2009, the Archive Team (not to be confused with the archive.org Archive-It Team) is a rogue archivist collective dedicated to saving copies of rapidly dying or deleted websites for the sake of history and digital heritage. The group is 100% composed of volunteers and interested parties, and has expanded into a large amount of related projects for saving online and digital history.

@mweststrate With 6.0 out now (👏 ), would you consider trimming down README and consolidate that at the docs site I've made? I still haven't got any feedback about that site from you.
https://mobx-react.js.org
The text was updated successfully, but these errors were encountered: