From a7c282ca348c1e8e60559e5c064caee28ba11eec Mon Sep 17 00:00:00 2001
From: Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com>
Date: Wed, 9 Oct 2024 16:34:12 +0300
Subject: refactor: so much shit

---
 frontend/src/api/Rankings.tsx | 13 +++++++++++++
 1 file changed, 13 insertions(+)
 create mode 100644 frontend/src/api/Rankings.tsx

(limited to 'frontend/src/api/Rankings.tsx')

diff --git a/frontend/src/api/Rankings.tsx b/frontend/src/api/Rankings.tsx
new file mode 100644
index 0000000..384f826
--- /dev/null
+++ b/frontend/src/api/Rankings.tsx
@@ -0,0 +1,13 @@
+import axios from "axios";
+import { url } from "./Api";
+import { Ranking, SteamRanking } from "../types/Ranking";
+
+export const get_official_rankings = async (): Promise<Ranking> => {
+  const response = await axios.get(url(`rankings/lphub`));
+  return response.data.data;
+};
+
+export const get_unofficial_rankings = async (): Promise<SteamRanking> => {
+  const response = await axios.get(url(`rankings/steam`));
+  return response.data.data;
+};
-- 
cgit v1.2.3

