André, meu package.json está assim:
{
"name": "cdc-admin",
"version": "0.1.0",
"private": true,
"dependencies": {
"ajv": "^6.0.0",
"jquery": "^3.3.1",
"pubsub-js": "^1.7.0",
"react": "^16.6.0",
"react-dom": "^16.6.0",
"react-router": "^3.2.1",
"react-scripts": "2.0.5"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
]
}
E o Index.js está assim:
import React from 'react';
import ReactDOM from 'react-dom';
import App from './App';
import './index.css';
import {Router, Route} from 'react-router';
import * as serviceWorker from './serviceWorker';
ReactDOM.render(
(<Router>
<Route path="/" component={App}/>
<Route path="/autor"/>
<Route path="/livro"/>
</Router>),
document.getElementById('root'));
serviceWorker.unregister();