Frontend updates: caching basic data (json) from CDragon
Implement caching in the patch_detector, consume the cache from API routes in frontend
This commit is contained in:
@@ -1,11 +1,7 @@
|
||||
import { CDRAGON_BASE } from '~/utils/cdragon'
|
||||
import { getChampionSummary } from '~/server/utils/cdragon-cache'
|
||||
|
||||
async function championRoutes() {
|
||||
const championsData: Array<Champion> = await (
|
||||
await fetch(
|
||||
CDRAGON_BASE + 'plugins/rcp-be-lol-game-data/global/default/v1/champion-summary.json'
|
||||
)
|
||||
).json()
|
||||
const championsData = await getChampionSummary()
|
||||
|
||||
const routes: Array<string> = []
|
||||
for (const champion of championsData) {
|
||||
|
||||
Reference in New Issue
Block a user