Closed atherdon closed 6 years ago
On the tutorial I saw how to organize better my components, how they should have a specific purpose so later on can be re-used. When returning multiple elements on the render of a component they must be wrapped or inside an array otherwise we'll get an error.
I have a question regarding of having all the static data into on file, should all the static text of my app go there as a good practice? When its full sentences I don't have a problem but when I'm using string interpolation I always struggle to know what's the better approach seems weird to create a constant for a fragment sentence.
PR Done, let me know if anything could be improved
passing static text/labels into separate file is just a habit. in previous company we tried to make websites templates more clear so this approach helping, it also good thing, if you have a multy language system. So for me
On 08-Jul-2018 at 02:30 PM, Alejandro Dietta wrote:
On the tutorial I saw how to organize better my components, how they should have a specific purpose so later on can be re-used. When returning multiple elements on the render of a component they must be wrapped or inside an array otherwise we'll get an error.
I have a question regarding of having all the static data into on file, should all the static text of my app go there as a good practice? When its full sentences I don't have a problem but when I'm using string interpolation I always struggle to know what's the better approach seems weird to create a constant for a fragment sentence.
PR Done, let me know if anything could be improved
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/GroceriStar/react-intern-only-27/issues/4#issuecomment-403291688, or mute the thread https://github.com/notifications/unsubscribe-auth/ABZrDlYlyejGBYISZ45NsJRywrQrMZU0ks5uEheJgaJpZM4VFxIM .
https://medium.com/quick-code/lets-learn-react-chapter-3-components-components-components-3492f771d623
Expected result
Test
1