React is a Javascript frontend library and if you want to get started with React first you have to learn Javascript, the programming language that ...
For further actions, you may consider blocking this person and/or reporting abuse
A few missing things I noticed where missing or incomplete:
returnkeyword always, so you can write thatsubtractfunction like this:And
Applike this:Classes and the Extend keyword: Worth mentioning that nowadays you don't need classes for components in React (Error boundaries are the only exception, and you can still use npm dependencies to not use classes for that either).
Async/Await: Before learning
async/awaitis key folks understand Promises. An example of thatgetPersonsInfofunction withoutasync/awaitto illustrate:Is also important to notice that using async functions in side effects with
useEffectis far from ideal.Array methods: Important resource when working with React: doesitmutate.xyz/ ... that site shows which methods change the original data and which ones don't. You should try to avoid mutations in React, so stay away from the methods that change the original data.
Template Literal: They are way more powerful than plain strings, because they also provide a way of using a function next to them. More info here. I use that approach in one of my libs.
Deconstructing: Deconstructing is quite convinient in function components, and can be done directly on the head of the function:
And also is worth mentioning that you can set default values for optional properties:
Also, your example has a typo when deconstructing objects.
Spread Operator: To concat arrays, nowadays is still faster to use
Array.prototype.concat, but for stuff like copying object properties is actually really convenient.Import and Export: In the export example you're missing the
exportkeyword. And is also important to mention that you can import and export named and default, so ideally we should have 4 examples.Code Hello World project with React: You mention a link to download Node, but didn't provided it. Also the command to run
create-react-appis actually:And the default app is already a "hello world" of sorts, so idk if this point makes much sense.
That's it! Cheers!
Hello @lukeshiru
Ty for reading the article.
Noted all your remarks
ππ
Just PM you on Twitter.
ππ
In case you have time for a small chat, thanks in advance.
Nice article. Thanks
This is really important for the react developers. Article is clean and can understand concepts simply. Thank you for sharing. β₯οΈ
Ty for reading Samitha.
ππ
This is great, ty!
ππ
Nice ..
ππ
This is a really really good breakdown of the concepts and a few things have just clicked in my mind thanks to reading this. Cheers!
Ty for reading @bangsluke
ππ
Thanks for the article!
ππ
Nice tutorial.
ππ
Really useful
ππ
Nice overview. You have a misspelling in your subtract function example, FYI. It would also be helpful and raise some questions if you mention anonymous vs named functions. Thanks for the breakdown.
Noted & ty for reading!
ππ
DOMs
Noted. ππ
Thanks dude, gonna need this in the futureπ
ππ