📅  最后修改于: 2022-03-11 15:02:03.195000             🧑  作者: Mango
React router as a browserRouter in App.js for navbar links like Home,
services,conatct-us etc.
// npm install react-router-dom
// ##### Basic Routing #####
import React from 'react';
import { BrowserRouter as Router, Switch, Route, Link } from 'react-router-dom';
export default function App() {
return (
{/* A looks through its children s and
renders the first one that matches the current URL. */}
);
}
function Home() {
return Home
;
}
function About() {
return About
;
}
function Users() {
return Users
;
}