このコミットが含まれているのは:
2026-02-04 23:08:28 +09:00
コミット 57f28e4e5e
16個のファイルの変更74行の追加132行の削除
+3 -6
ファイルの表示
@@ -1,12 +1,11 @@
import axios from 'axios'
import toCamel from 'camelcase-keys'
import { useEffect, useState } from 'react'
import { Helmet } from 'react-helmet-async'
import { useLocation } from 'react-router-dom'
import PrefetchLink from '@/components/PrefetchLink'
import MainArea from '@/components/layout/MainArea'
import { API_BASE_URL, SITE_TITLE } from '@/config'
import { SITE_TITLE } from '@/config'
import { apiGet } from '@/lib/api'
import type { WikiPageChange } from '@/types'
@@ -20,9 +19,7 @@ export default () => {
useEffect (() => {
void (async () => {
const res = await axios.get (`${ API_BASE_URL }/wiki/changes`,
{ params: { ...(id ? { id } : { }) } })
setChanges (toCamel (res.data as any, { deep: true }) as WikiPageChange[])
setChanges (await apiGet<WikiPageChange[]> ('/wiki/changes', { params: id ? { id } : { } }))
}) ()
}, [location.search])