API自動生成型のエイリアス定義をtypeAliases.tsに集約#239
Conversation
|
Preview (prod) → https://239-prod.rucq-ui-preview.trapti.tech/ |
|
Warning Review limit reached
More reviews will be available in 2 minutes and 9 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (33)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
OpenAPI 生成型(@/api/schema)のレスポンス型エイリアス定義を src/typeAliases.ts に集約し、各コンポーネント/ストアからのボイラープレートな型定義を削減するPRです。型参照元を統一することで、型の利用方法の一貫性と保守性を高めます。
Changes:
src/typeAliases.tsを新設し、components['schemas'][...]ベースの型エイリアスを一箇所に集約- 各 Vue コンポーネント/ユーティリティ/ストアで
@/api/schema直接参照を廃止し@/typeAliases参照へ置換 - 一部のジェネリクス指定(例:
QuestionGroup[])を、新しいエイリアス形に合わせて調整
Reviewed changes
Copilot reviewed 33 out of 33 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/typeAliases.ts | OpenAPI schema 由来の型エイリアスを集約する新規ファイルを追加 |
| src/views/UserInfoView.vue | QuestionGroup/Dashboard 型参照を typeAliases に統一、useQuery の型を QuestionGroup[] に調整 |
| src/views/ScheduleView.vue | CampEvent 型参照を typeAliases に統一 |
| src/views/RoomInfoView.vue | RoomGroup 型参照を typeAliases に統一 |
| src/views/RollCallView.vue | RollCall 型参照を typeAliases に統一 |
| src/views/RegistrationView.vue | Camp 型参照を typeAliases に統一 |
| src/views/ActivityView.vue | Activity 型参照を typeAliases に統一(テンプレート整形含む) |
| src/store.ts | User/Camp 型参照を typeAliases に統一、participants 取得の型を User[] に統一 |
| src/mocks/activities.ts | Activity 型参照を typeAliases に統一 |
| src/components/room/RoomStatusDialog.vue | Room/RoomStatus/RoomStatusLog 型参照を typeAliases に統一 |
| src/components/room/RoomCard.vue | Room 型参照を typeAliases に統一 |
| src/components/rollcall/rollCallStream.ts | RollCall 系型参照を typeAliases に統一 |
| src/components/information/*.vue | Question/Answer/Room/Payment など情報系コンポーネントの型参照を typeAliases に統一 |
| src/components/event/**/*.ts, *.vue | Event/Camp 系型参照を typeAliases に統一 |
| src/components/activity/*.vue | Activity 型参照を typeAliases に統一 |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

closes #172
古くなってコンフリクトが発生してどうにもならなくなっていた #214 をやり直したもの
これまでのコードでは各コンポーネントで
のようなボイラープレートによって型を使用していましたが、これを typeAliases.ts に集約します