REACT render multiple elements react - Net-Raft.com

Welcome aboard! We are happy you are here and wish you good net-raft!




Just a Web Code Solution

how to render multiple elements using react ?


 159

REACT


2

import React from 'react';

class App extends React.Component {
render() {
return (
<div>
Hello World!!!
</div>
);
}
}

export default App


By     Created   
The power of the user (%)
5%

Show ResultREACT


1

<!DOCTYPE html>
<html>
<head>
<script src="https://fb.me/react-0.14.3.min.js"></script>
<script src="https://fb.me/react-dom-0.14.3.min.js"></script>
</head>
<body>

<p id="app"></p>

<script type="text/javascript">

var div = React.DOM.div
var span = React.DOM.span
var p = React.DOM.p
var button = React.DOM.button

var HelloWorldComponent = (
div(null,
span({id:"test", style: {color: "black", backgroundColor: "yellow"}},"Hello world!"),
p(null),
button(null,"click")

)

)

ReactDOM.render(HelloWorldComponent, document.getElementsByTagName('body')[0]);

</script>

</body>
</html>


By     Created   
The power of the user (%)
6%



The most helpful REACT solutions

How to get client ip address using react ?How to get client ip address using react ?REACT

Click to see more ...

  7.8K     421

how to get the type of a device using react ?how to get the type of a device using react ?REACT

Click to see more ...

  1.8K     214

create digital clock reactcreate digital clock reactREACT

Click to see more ...

  1.2K     141

country dropdown using reactcountry dropdown using reactREACT

Click to see more ...

  921     127

How to get latitude and longitude using react/javascript ?How to get latitude and longitude using react/javascript ?REACT

Click to see more ...

  790     108

create alarm clock using reactcreate alarm clock using reactREACT

Click to see more ...

  3K     84

get client country reactget client country reactREACT

Click to see more ...

  509     82

get ip address reactget ip address reactREACT

Click to see more ...

  562     80

time ago reacttime ago reactREACT

Click to see more ...

  382     74

detect mobile device reactdetect mobile device reactREACT

Click to see more ...

  366     58