Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
Formation-React-Pitoune
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pitoune
Formation-React-Pitoune
Commits
c7d4e438
Commit
c7d4e438
authored
3 years ago
by
Viarezo
Browse files
Options
Downloads
Patches
Plain Diff
first clean version
parent
72b8fb8f
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
public/index.html
+3
-26
3 additions, 26 deletions
public/index.html
src/App.js
+6
-16
6 additions, 16 deletions
src/App.js
src/Counter.js
+25
-0
25 additions, 0 deletions
src/Counter.js
with
34 additions
and
42 deletions
public/index.html
+
3
−
26
View file @
c7d4e438
...
@@ -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>
This diff is collapsed.
Click to expand it.
src/App.js
+
6
−
16
View file @
c7d4e438
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
>
);
);
}
}
...
...
This diff is collapsed.
Click to expand it.
src/Counter.js
0 → 100644
+
25
−
0
View file @
c7d4e438
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
"
}}
>
Là
genre
ça
vaut
{
count
}
<
/p
>
<
/div
>
)
};
export
{
Counter
};
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment