We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8f5f966 commit deddf47Copy full SHA for deddf47
src/components/NavBar.js
@@ -0,0 +1,44 @@
1
+import React from "react";
2
+import { NavLink } from "react-router-dom";
3
+
4
+export default function NavBar() {
5
+ const linkStyle = {
6
+ color: "white",
7
+ textDecoration: "none",
8
+ marginRight: "20px",
9
+ fontSize: "18px"
10
+ };
11
12
+ const activeStyle = {
13
+ textDecoration: "underline"
14
15
16
+ return (
17
+ <nav
18
+ style={{
19
+ width: "100%",
20
+ padding: "12px 20px",
21
+ backgroundColor: "#222",
22
23
+ display: "flex",
24
+ alignItems: "center"
25
+ }}
26
+ >
27
+ <NavLink
28
+ to="/"
29
+ style={linkStyle}
30
+ activeStyle={activeStyle}
31
32
+ Home
33
+ </NavLink>
34
35
36
+ to="/about"
37
38
39
40
+ About
41
42
+ </nav>
43
+ );
44
+}
0 commit comments