diff options
author | eug-vs <eug-vs@keemail.me> | 2020-03-21 15:06:30 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2020-03-21 15:06:30 +0300 |
commit | f3a684937565f3bd94034f3389aa95fea908f0c4 (patch) | |
tree | c01492bf8c06dc5409f9d8a30e807786dea90308 /src/requests.ts | |
parent | de2a49bf1bf0e4c2f09ddcd0f2a86dff7062d8ea (diff) | |
download | chrono-cube-ui-f3a684937565f3bd94034f3389aa95fea908f0c4.tar.gz |
chore: fix linting errors :rotating_light:
Diffstat (limited to 'src/requests.ts')
-rw-r--r-- | src/requests.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/requests.ts b/src/requests.ts index eeb2ee7..961d8d6 100644 --- a/src/requests.ts +++ b/src/requests.ts @@ -1,22 +1,22 @@ -import axios from 'axios' +import axios, { AxiosResponse } from 'axios'; const baseUrl = 'https://eugvs.pythonanywhere.com/'; const baseApiUrl = baseUrl + 'api/'; -export const get = (url: string) => { +export const get = (url: string): Promise<AxiosResponse> => { return axios.get( baseApiUrl + url, ); }; -export const post = (url: string, data: object) => { +export const post = (url: string, data: object): Promise<AxiosResponse> => { return axios.post( baseApiUrl + url, data ); }; -export const del = (url: string, data: object) => { +export const del = (url: string, data: object): Promise<AxiosResponse> => { return axios.delete( baseApiUrl + url, data |