Skip to content
Snippets Groups Projects
Commit c7d4e438 authored by Viarezo's avatar Viarezo
Browse files

first clean version

parent 72b8fb8f
Branches
No related tags found
No related merge requests found
...@@ -4,40 +4,17 @@ ...@@ -4,40 +4,17 @@
<meta charset="utf-8" /> <meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" /> <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" /> <meta name="theme-color" content="#123456" />
<meta <meta
name="description" name="description"
content="Web site created using create-react-app" content="C'est mon site wesh"
/> />
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-uWxY/CJNBR+1zjPWmfnSnVxwRheevXITnMqoEIeG1LJrdI0GlVs/9cVSyPYXdcSF" crossorigin="anonymous">
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" /> <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title> <title>React App</title>
</head> </head>
<body> <body>
<noscript>You need to enable JavaScript to run this app.</noscript> <noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div> <div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
You can add webfonts, meta tags, or analytics to this file.
The build step will place the bundled scripts into the <body> tag.
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body> </body>
</html> </html>
import logo from './logo.svg';
import './App.css'; import './App.css';
import { Counter } from './Counter.js';
function App() { const App = () => {
return ( return (
<div className="App"> <div className="App">
<header className="App-header"> <div style={{background:'lightblue', borderRadius:'1em', padding: "2em", margin: "1em"}}>
<img src={logo} className="App-logo" alt="logo" /> <h1>Bienvenue dans notre super site !</h1>
<p> </div>
Edit <code>src/App.js</code> and save to reload. <Counter/>
</p>
<a
className="App-link"
href="https://reactjs.org"
target="_blank"
rel="noopener noreferrer"
>
Learn React
</a>
</header>
</div> </div>
); );
} }
......
import { useState } from "react";
const Counter = () => {
const [count, setCount] = useState(0);
console.log({count});
document.title = "La page n°"+toString({count});
return (
<div class="card" style={{width:"30em", margin: '0 auto'}}>
<div class="card-header">
Par exemple, on va voir les boutons
</div>
<button
type="button"
class="btn btn-primary"
onClick={()=>setCount(count+1)}
style={{margin: "1em"}}
>
Ce bouton incrémente
</button>
<p style={{marginBottom: "1em"}}> genre ça vaut {count}</p>
</div>
)
};
export { Counter };
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment