diff options
author | eug-vs <eug-vs@keemail.me> | 2020-03-21 14:35:19 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2020-03-21 14:35:19 +0300 |
commit | e32c8be0a4b7f135c01449c3603da347728819a8 (patch) | |
tree | 499eeb9d2ab81481e6828f53cc8ab89ed14821f1 | |
parent | bfc2a9bc3c1ecbef31e76e36fed79a8500f0d0fd (diff) | |
download | chrono-cube-ui-e32c8be0a4b7f135c01449c3603da347728819a8.tar.gz |
chore: migrate requests.ts
-rw-r--r-- | src/requests.ts (renamed from src/requests.js) | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/requests.js b/src/requests.ts index ad45dcf..eeb2ee7 100644 --- a/src/requests.js +++ b/src/requests.ts @@ -3,20 +3,20 @@ import axios from 'axios' const baseUrl = 'https://eugvs.pythonanywhere.com/'; const baseApiUrl = baseUrl + 'api/'; -export const get = (url) => { +export const get = (url: string) => { return axios.get( baseApiUrl + url, ); }; -export const post = (url, data) => { +export const post = (url: string, data: object) => { return axios.post( baseApiUrl + url, data ); }; -export const del = (url, data) => { +export const del = (url: string, data: object) => { return axios.delete( baseApiUrl + url, data |