Добавлен заголовок с Content-Type

This commit is contained in:
goodmice 2021-12-02 15:12:22 +05:00
parent c5a7470d34
commit 2c585ab227

View File

@ -13,19 +13,20 @@ import { PrivateRoute } from './components/Private'
//OpenAPI.BASE = 'http://localhost:3000'
OpenAPI.TOKEN = localStorage['token']
OpenAPI.HEADERS = {'Content-Type': 'application/json'}
export default function App() {
return (
<ConfigProvider locale={locale}>
<Router>
<Switch>
<Route path="/login">
<Route path={'/login'}>
<Login />
</Route>
<Route path="/register">
<Route path={'/register'}>
<Register />
</Route>
<PrivateRoute path="/">
<PrivateRoute path={'/'}>
<Main />
</PrivateRoute>
</Switch>