const formatUrl = (url: string, path: object) => {
const reg = new RegExp(/{(w+)}/, "g");
return url.replace(reg, ($0: any, $1: any) => {
return path[$1];
});
};
const formatUrl = (url: string, path: object) => {
const reg = new RegExp(/{(w+)}/, "g");
return url.replace(reg, ($0: any, $1: any) => {
return path[$1];
});
};