Skip to content

Commit 9c03406

Browse files
committed
Add numeric display text to current points value
1 parent f278122 commit 9c03406

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/App.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import CostDisplay from './components/CostDisplay/CostDisplay';
2+
import NumericDisplay from './components/NumericDisplay/NumericDisplay';
23
import './App.css';
34
import { useState, useEffect } from 'react';
45
function App() {
@@ -70,7 +71,10 @@ function App() {
7071
<p>Click the button to add points!</p>
7172
{/*display current points value*/}
7273
<p>
73-
Points: <div id="points-display">{points}</div>
74+
Points:{" "}
75+
<div id="points-display">
76+
<NumericDisplay value={points} />
77+
</div>
7478
</p>
7579
{/*increase points from clicking a button*/}
7680
<button onClick={() => addPointsFromClick()}>Click to Add Points</button>

0 commit comments

Comments
 (0)