diff --git a/app/api/workExperience/fetch.ts b/app/api/workExperience/fetch.ts index c256a48..aab03bd 100644 --- a/app/api/workExperience/fetch.ts +++ b/app/api/workExperience/fetch.ts @@ -15,11 +15,11 @@ type Response = { limit: number; }; -const fetchWorkExperience = async (c: Context) => { +const fetchWorkExperiences = async (c: Context) => { const res = await apiClient.GET(c, "/work-experience"); return res.contents.map((content) => { return { ...content }; }); }; -export { fetchWorkExperience }; +export { fetchWorkExperiences }; diff --git a/app/components/history/HistoryPresenter.tsx b/app/components/history/HistoryPresenter.tsx index e587c3d..2fa4549 100644 --- a/app/components/history/HistoryPresenter.tsx +++ b/app/components/history/HistoryPresenter.tsx @@ -5,15 +5,15 @@ import { presenterLayout } from "./HistoryPresenter.css"; import { HistoryWorkExperience } from "./HistoryWorkExperience"; type Props = { - workExperience: WorkExperience[]; + workExperiences: WorkExperience[]; }; const HistoryPresenter: FC = (props) => { - const { workExperience } = props; + const { workExperiences } = props; return (
- +
); diff --git a/app/components/history/HistoryWorkExperience.tsx b/app/components/history/HistoryWorkExperience.tsx index 16fc76c..c7ec328 100644 --- a/app/components/history/HistoryWorkExperience.tsx +++ b/app/components/history/HistoryWorkExperience.tsx @@ -4,16 +4,16 @@ import { Section } from "../Section"; import { workExperienceDescription, workExperienceList } from "./HistoryWorkExperience.css"; type Props = { - workExperience: WorkExperience[]; + workExperiences: WorkExperience[]; }; const HistoryWorkExperience: FC = (props) => { - const { workExperience } = props; + const { workExperiences } = props; return (
    - {workExperience + {workExperiences .toSorted((a, b) => a.order - b.order) .map((item) => (
  • diff --git a/app/routes/history.tsx b/app/routes/history.tsx index fe66472..6f35c4f 100644 --- a/app/routes/history.tsx +++ b/app/routes/history.tsx @@ -1,8 +1,8 @@ import { createRoute } from "honox/factory"; import { HistoryPresenter } from "../components/history/HistoryPresenter"; -import { fetchWorkExperience } from "../api/workExperience"; +import { fetchWorkExperiences } from "../api/workExperience"; export default createRoute(async (c) => { - const workExperience = await fetchWorkExperience(c); - return c.render(); + const workExperiences = await fetchWorkExperiences(c); + return c.render(); });