BrowserRouter in React with TypeScript
I have a simple application in React + TypeScript. I'm trying to use the BrowserRouter from react-router-dom. This is my code: import * as React from "react" import { Popular } from "./popular" import { BrowserRouter as Router, Route } from "react-router-dom" export interface AppProp { } export interface AppState { } export class App extends React.Component<AppProp , AppState > { render() { return ( <div className='container'> <Router> <Route path='/popular' component={Popular} /> </Router> </div> ) } } export default App I'm getting the following errors: ERROR in [at-loader] ./node_modules/@t
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.