Add project files
This commit is contained in:
28
react-project/src/App.js
vendored
Normal file
28
react-project/src/App.js
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
import React, { useState } from 'react';
|
||||
import './App.css';
|
||||
|
||||
function App() {
|
||||
const [count, setCount] = useState(0);
|
||||
|
||||
return (
|
||||
<div className="App">
|
||||
<header className="App-header">
|
||||
<h1>React Docker Demo</h1>
|
||||
<p>Diese App läuft in einem Docker-Container</p>
|
||||
|
||||
<div className="counter">
|
||||
<p>Du hast den Button {count} mal geklickt</p>
|
||||
<button onClick={() => setCount(count + 1)}>
|
||||
Klick mich!
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<p className="info">
|
||||
Build-Zeit: {process.env.REACT_APP_BUILD_TIME || 'Unbekannt'}
|
||||
</p>
|
||||
</header>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default App;
|
||||
Reference in New Issue
Block a user