1
0
mirror of https://github.com/danbee/chess synced 2025-03-04 08:39:06 +00:00
chess/assets/js/services/api.js

14 lines
240 B
JavaScript

import axios from "axios";
const API = {
getGame: (gameId) => {
return axios.get(`/api/games/${gameId}`);
},
updateGame: (gameId, move) => {
return axios.patch(`/api/games/${gameId}`, { move });
},
};
export default API;