-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
Update thinking-in-react.md #2095
Conversation
Please refer to https://justsimply.dev for the thinking behind these proposed changes.
Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign up at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need the corporate CLA signed. If you have received this in error or have any questions, please contact us at [email protected]. Thanks! |
Deploy preview for reactjs ready! Built with commit 0328b63 |
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks! |
|
||
Since you're often displaying a JSON data model to a user, you'll find that if your model was built correctly, your UI (and therefore your component structure) will map nicely. That's because UI and data models tend to adhere to the same *information architecture*, which means the work of separating your UI into components is often trivial. Just break it up into components that represent exactly one piece of your data model. | ||
Since you're often displaying a JSON data model to a user, you'll find that if your model was built correctly, your UI (and therefore your component structure) will map nicely. That's because UI and data models tend to adhere to the same *information architecture*, which means the work of separating your UI into components is often trivial. Break it up into components that represent exactly one piece of your data model. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"trivial" might be another one of those words - @EmmaB any idea for an alternative (can do a followup PR)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"often mirrors the data model" or something like that 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps something like: "That's because UI and data models tend to adhere to the same information architecture. Separate your UI into components, where each component matches one piece of your data model." I'll put it on a PR, with thanks!
Good call 💯 |
Follow up to reactjs#2095 (comment)
Wonderful change, thank you @EmmaB! |
Follow up to #2095 (comment)
* Update thinking-in-react.md (#2095) Please refer to https://justsimply.dev for the thinking behind these proposed changes. * Update thinking-in-react.md (#2098) Follow up to reactjs/react.dev#2095 (comment) * Add missing function call to example (#2102) An example for useEffect omitted the actual invocation of the function in question. * resolve merge conflicts
* Update thinking-in-react.md (#2095) Please refer to https://justsimply.dev for the thinking behind these proposed changes. * Update thinking-in-react.md (#2098) Follow up to reactjs/react.dev#2095 (comment) * Add missing function call to example (#2102) An example for useEffect omitted the actual invocation of the function in question. * Fix conflict
* Update thinking-in-react.md (#2095) Please refer to https://justsimply.dev for the thinking behind these proposed changes. * Update thinking-in-react.md (#2098) Follow up to reactjs/react.dev#2095 (comment) * Add missing function call to example (#2102) An example for useEffect omitted the actual invocation of the function in question. * Add description of PropTypes.exact (#1581) Info from https://github.com/facebook/prop-types#usage * Improve grammar (#2106) * Fixed minor code-splitting.md typo (#1292) * Fixed minor code-splitting.md typo * Update code-splitting.md Co-authored-by: Alexey Pyltsyn <[email protected]> * Fixed broken link to discuss.react.org (#2107) * Replaced broken discuss.reactjs.org link On the how-to-contribute page, there is a broken link under the https://reactjs.org/docs/how-to-contribute.html#how-to-get-in-touch section. As outlined in reactjs/react.dev#2080 `discuss.reactjs.org` isn't reachable. I edited the text to display `Discussion Forums` which links to https://reactjs.org/community/support.html#popular-discussion-forums (as I was unable to find an official reactjs discussion forum). * fixed text case changed `Discussion Forums` to `Discussion forums` * Update 2019-02-23-is-react-translated-yet.md (#2109) * Add Meetup (#2097) Add JaipurJS - JavaScript meetup in Jaipur, Rajasthan, India * [docs] Updated required node and npm versions to match CRA docs in 'docs/create-a-new-react-app.html' (#2099) https://facebook.github.io/create-react-app/docs/getting-started * Remove tooling support info in fragment docs (#2096) * Correct the description of when gDSFP gets called (#2100) * Added free Scrimba React Tutorial (#2111) A great video/editor tutorial consisting of 48 hands-on lessons. * Update Production Optimization docs to use terser (#2112) * Update Production Optimization docs to use terser * Update Optimizing Performance.md * Fix typo Co-Authored-By: Alexey Pyltsyn <[email protected]> * Update hooks-faq.md (#2113) * Update hooks-faq.md I tripped up slightly while reading this example for using the callback form of a state setter inside an effect. I've added a few lines that might help a hook newbie grok the differences between the examples. * Update hooks-faq.md * Update hooks-faq.md * Update tutorial.md (#2115) changed 'any React apps' to 'any React app' * move past conferences to the bottom of the list (#2118) * fix(Blog): Post title updated to correct word for yes word in spanish (#2122) * Revert "fix(Blog): Post title updated to correct word for yes word in spanish (#2122)" (#2130) This reverts commit 06a029d. * Add DevExtreme Reactive to the Components list (#2127) * [Documentation] Fix: Update link to Chrome Accessibility Inspec… (#2134) * React Native added support for hooks in 0.59 (#2121) * React Native added support for hooks in 0.59 React Native 0.59 and above already support React Hooks, this line is no longer necessary, causes confusion for some people that it is not working right now. We can also mention React Native version if needed. * update with react native mention of hooks support * Update content/docs/hooks-faq.md suggested changes Co-Authored-By: Alexey Pyltsyn <[email protected]> * Add Kiel to the list of React Meetups (#2136) * Reduce confusion about adding additional fields to .this (#2142) As a new React learner, this part was a bit confusing as I though that it was referencing `() => this.tick()` part of the code. My addition would help at least people like me. * Added option for more cdns. (#2144) * Update docs about an existence of .elementType (#2145) Hi, I've met the same issue on [here](facebook/prop-types#200) at storybook and found the following [PR](facebook/prop-types#211) that adds the `elementType` feature. It could find the doc on npm, but not the official react site. * Revert "Added option for more cdns. (#2144)" (#2146) This reverts commit b84fb3d. * Add React Conf to list of community conferences (#2158) * Add React Conf to list of community conferences * Whoops, put right day in * docs(hooks): fix typo (#2161) * update the status of Arabic translation .. (#2157) * Fixing typo in contributing section of the docs (#2166) * Add a relevant FAQ link in "Thinking In React" (#2170)
Please refer to https://justsimply.dev for the thinking behind these proposed changes.