How to create a simple ‘Hello React’ app

Say “Hello” to improve your understanding of React basics.

Image for post
Image for post
Credit: Image originally by this guy on Reddit. Edited by me.

Real Quick

Creating in React

Image for post
Image for post

Create An Element

<div id="app">

</div>

Create Component

function Text(){
return (
<h1>Hello React</h1>
)
};

Render (the) Component

ReactDOM.render(
<Text/>, document.getElementById('app')
);

Footnote

ReactDOM.render(
<div>
<Text/>
<Image />
</div>, document.getElementById('app')
);

Written by

Entrepreneur, music aficionado, tech geek. Stephen is the founder of @codayetech, a software dev startup targeting the African market steve@codaye.com

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store