nekochans / lgtm-cat-frontend

lgtm-cat(サービス名 LGTMeow https://lgtmeow.com) のフロントエンド用
https://lgtmeow.com
21 stars 2 forks source link

LGTM画像を取得する処理をBFFを経由して取得するように変更 #240

Closed keitakn closed 1 year ago

keitakn commented 1 year ago

issueURL

https://github.com/nekochans/lgtm-cat-frontend/issues/237

関連 URL

https://lgtm-cat-frontend-git-feature-issue237change-g-252f0f-nekochans.vercel.app/

Done の定義

Storybook の URL もしくはスクリーンショット

UI変更はないのでなし。

変更点概要

LGTM画像を取得する処理をBFFを利用するように変更。

これでトークンの取得処理によるオーバーヘッドがなくなったので、処理速度が向上している。

さらにプレビュー環境でもCORSのエラー対策を行っているので、Cats RefreshNew arrival Cats を押下した時の処理が環境変数の書き換えなしでも動作するようになっている。

レビュアーに重点的にチェックして欲しい点

特になし

補足情報

画像アップロードに関する処理は別のPRで対応する。

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
lgtm-cat-frontend ✅ Ready (Inspect) Visit Preview Jan 15, 2023 at 3:30PM (UTC)
codecov[bot] commented 1 year ago

Codecov Report

Base: 75.29% // Head: 76.19% // Increases project coverage by +0.89% :tada:

Coverage data is based on head (807477e) compared to base (6ba4f4f). Patch coverage: 93.75% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #240 +/- ## ========================================== + Coverage 75.29% 76.19% +0.89% ========================================== Files 52 52 Lines 510 504 -6 Branches 134 132 -2 ========================================== Hits 384 384 + Misses 120 115 -5 + Partials 6 5 -1 ``` | [Impacted Files](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans) | Coverage Δ | | |---|---|---| | [src/features/lgtmImage.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL2ZlYXR1cmVzL2xndG1JbWFnZS50cw==) | `50.00% <ø> (ø)` | | | [src/mocks/api/fetchLgtmImagesMockBody.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL21vY2tzL2FwaS9mZXRjaExndG1JbWFnZXNNb2NrQm9keS50cw==) | `100.00% <ø> (ø)` | | | [src/features/url.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL2ZlYXR1cmVzL3VybC50cw==) | `78.37% <83.33%> (-0.41%)` | :arrow_down: | | [src/api/fetch/authToken.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL2FwaS9mZXRjaC9hdXRoVG9rZW4udHM=) | `100.00% <100.00%> (+41.17%)` | :arrow_up: | | [src/api/fetch/lgtmImage.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL2FwaS9mZXRjaC9sZ3RtSW1hZ2UudHM=) | `86.11% <100.00%> (ø)` | | | [src/hooks/useCatImagesFetcher.ts](https://codecov.io/gh/nekochans/lgtm-cat-frontend/pull/240?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans#diff-c3JjL2hvb2tzL3VzZUNhdEltYWdlc0ZldGNoZXIudHM=) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=nekochans)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.