但是在路由后,如果页面刷新,则index.js中建立的基本组件不会像ResetCSS组件那样再次呈现,请帮帮我。
<BrowserRouter history={history}>
<ThemeProvider theme={appTheme}>
<>
<Head>
<title>Roots And Leaves</title>
<meta name="Description" content="React next landing page" />
<meta name="theme-color" content="#ec5555" />
<link
href="https://fonts.googleapis.com/css?family=Open+Sans:300,400,700"
rel="stylesheet"
/>
</Head>
<ResetCSS />
<GlobalStyle />
<AppWrapper>
<Sticky top={0} innerZ={9999} activeClass="sticky-nav-active">
<DrawerProvider>
<Navbar />
</DrawerProvider>
</Sticky>
<Route exact path="/" component={Home} />
<Route exact path="/home" component={Home} />
<Route exact path="/faq" component={FAQ} />
<Route exact path="/about" component={About} />
<Route exact path="/popc" component={PopC} />
<Route exact path="/blog" component={Blog} />
<Route exact path="/policy" component={Policy} />
<Route exact path="/career" component={Career} />
<Route exact path="/contact" component={Contact} />
<Footer />
</AppWrapper>
</>
</ThemeProvider>
</BrowserRouter>