Add react
This commit is contained in:
22
src/app.js
Normal file
22
src/app.js
Normal file
@ -0,0 +1,22 @@
|
||||
import React from 'react';
|
||||
class Verification extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
}
|
||||
componentDidMount() {
|
||||
const apiUrl = 'https://thanos.nightmare.haus/api/verifications';
|
||||
fetch(apiUrl)
|
||||
.then((response) => response.json())
|
||||
.then((data) => console.log('The data from the call: ', data));
|
||||
}
|
||||
render() {
|
||||
return (
|
||||
<div><h1>Verifications have loaded. See logs.</h1></div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
ReactDOM.render(
|
||||
<Verification />,
|
||||
document.getElementById('react_app')
|
||||
);
|
||||
Reference in New Issue
Block a user