Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<!-- Closeするissue番号 -->
## 関連 Issue

- Close #

## やったこと
Expand All @@ -7,10 +8,4 @@

## 確認した方法


## スクリーンショット


## 自動生成したコード

- ファイル名
4 changes: 2 additions & 2 deletions .github/workflows/publish-spec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ jobs:
node-version: '22'

- name: Bundle API
working-directory: api
working-directory: openapi
run: |
npm run bundle

- name: Generate Swagger UI
uses: Legion2/swagger-ui-action@v1
with:
output: swagger-ui
spec-file: ./api/bundle.yml
spec-file: ./openapi/bundle.yml
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Publish to Cloudflare Pages
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/validate-spec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ jobs:

- name: Validate API Specification
run: |
redocly lint ./api/openapi.yml
redocly lint ./openapi/openapi.yml
2 changes: 1 addition & 1 deletion README.dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ npm install -g @stoplight/prism-cli
モックサーバの起動

```
prism mock ./api/openapi.yml
prism mock ./openapi/openapi.yml
```
File renamed without changes.
6 changes: 4 additions & 2 deletions api/README.md → openapi/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## ディレクトリ構造

```
api
openapi
├── bundle.yml ... APIに仕様を1つにまとめたYAMLファイル
├── components ... 使い回すために部品化された仕様
│   ├── examples
Expand All @@ -15,11 +15,13 @@ api
## CLI

バリデーション

```
$ npm run lint
```

APIの仕様を1つのYAMLファイルにまとめる
API の仕様を 1 つの YAML ファイルにまとめる

```
$ npm run bundle
```
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions orval.config.dev.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
client: {
input: {
target: './api/bundle.yml',
target: './openapi/bundle.yml',
},
output: {
client: 'react-query',
Expand All @@ -19,7 +19,7 @@ module.exports = {
},
msw: {
input: {
target: './api/bundle.yml',
target: './openapi/bundle.yml',
},
output: {
baseUrl: 'https://localhost:8787',
Expand All @@ -41,7 +41,7 @@ module.exports = {
},
zod: {
input: {
target: './api/bundle.yml',
target: './openapi/bundle.yml',
},
output: {
client: 'zod',
Expand Down
4 changes: 2 additions & 2 deletions orval.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
client: {
input: {
target: './api/bundle.yml',
target: './openapi/bundle.yml',
},
output: {
baseUrl: 'https://kitcc-library-api.kitcc.workers.dev',
Expand All @@ -19,7 +19,7 @@ module.exports = {
},
zod: {
input: {
target: './api/bundle.yml',
target: './openapi/bundle.yml',
},
output: {
client: 'zod',
Expand Down