Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Develop #9

Merged
merged 7 commits into from
Feb 14, 2025
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
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
run: echo "${{ secrets.DOTENV }}" > .env

- name: npm-install
run: npm i
run: npm i --legacy-peer-deps

- name: npm-build
run: npm run build
3 changes: 3 additions & 0 deletions next.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ const nextConfig: NextConfig = {
},
],
},
experimental: {
useCache: true,
},
}

export default nextConfig
104 changes: 57 additions & 47 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "medusa",
"version": "0.1.0",
"version": "0.2.0",
"private": true,
"scripts": {
"dev": "next dev --turbopack",
Expand All @@ -10,7 +10,8 @@
"lint": "next lint --fix",
"format": "prettier --write .",
"prepare": "husky",
"check:deps": "depcruise src"
"check:deps": "depcruise src",
"check:types": "tsx --noEmit"
},
"dependencies": {
"@date-fns/tz": "^1.2.0",
Expand All @@ -22,7 +23,7 @@
"date-fns": "^4.1.0",
"highcharts": "^11.4.8",
"highcharts-react-official": "^3.2.1",
"next": "15.1.3",
"next": "^15.2.0-canary.56",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Next.jsのバージョンについて気になる点があります

ご主人様、canaryバージョンを使用されているのが気になりました。本番環境での使用は安定性の面で少し心配です。

安定版への移行をご検討いただけますでしょうか?また、依存関係の互換性も確認させてください:


🏁 Script executed:

#!/bin/bash
# 依存パッケージの互換性チェック
npm ls next react react-dom

Length of output: 263


🌐 Web query:

What is the latest stable version of Next.js?

💡 Result:

The latest stable version of Next.js as of February 14, 2025 is Next.js 15.1.7, released on January 22, 2025[1][6]. This version follows Next.js's release channels where only stable releases are recommended for production use[1].

Key details:

  • Next.js 15 became stable in October 2024[3][5]
  • It requires React v19 and includes breaking changes like async request APIs (headers, cookies, etc.)[4]
  • The framework maintains two release channels: stable (production-ready) and canary (experimental)[1]

Developers can verify their installed version using:

npx next --version

For upgrades, Next.js provides a codemod CLI (@next/codemod) to automate migration from older versions like v14[4]. The current security-supported versions include both v14 and v15[1].

Citations:


Next.jsのバージョン管理についてご注意ください

ご主人様、依存関係の確認の結果、現在 package.json の26行目で指定されている Next.js の canary バージョン (15.2.0-canary.56) が利用されていますね。本番環境での安定運用を考慮すると、公式の安定版である 15.1.7 への移行をご検討くださいませ。

  • ファイル: package.json (行26)
    • 現状: "next": "^15.2.0-canary.56"
    • 推奨: 安定版 15.1.7 への更新
  • また、安定版に移行する際、React のバージョン(現在は 18.3.1)との互換性についても十分ご確認いただけますと安心です。

どうぞご検討くださいませ!

"react": "^18.3.1",
"react-dom": "^18.3.1",
"recharts": "^2.13.0-alpha.5",
Expand Down
Binary file added public/image/banner.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/image/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 16 additions & 1 deletion src/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
'use cache'

import { Analytics } from '@vercel/analytics/react'
import { SpeedInsights } from '@vercel/speed-insights/next'

Expand All @@ -12,9 +14,22 @@ export const metadata: Metadata = {
default: '閻魔帳',
},
description: 'チェイスチェイスジョーカーズのプレイ履歴を分析します。',
openGraph: {
title: '閻魔帳',
description: 'チェイスチェイスジョーカーズのプレイ履歴を分析します。',
url: 'https://放課後天地創造.club',
images: '/image/banner.png',
},
twitter: {
title: '閻魔帳',
description: 'チェイスチェイスジョーカーズのプレイ履歴を分析します。',
site: '@sweshelo',
images: '/image/banner.png',
},
icons: '/image/icon.png',
}

export default function RootLayout({
export default async function RootLayout({
children,
}: Readonly<{
children: React.ReactNode
Expand Down
2 changes: 2 additions & 0 deletions src/app/player/[name]/page.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
'use cache'

import { Metadata } from 'next'

import { PlayerPage } from '@/features/player'
Expand Down
2 changes: 2 additions & 0 deletions src/app/ranking/page.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
'use cache'

import { Metadata } from 'next'

import RankingPage from '@/features/ranking'
Expand Down
6 changes: 2 additions & 4 deletions src/components/header/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ import Link from 'next/link'
export const Header = () => {
return (
<Link href={'/'}>
<div className="w-full bg-blue-900">
<div className="w-full bg-red-900">
<div className="max-w-[800px] mx-auto p-4 flex items-center space-x-4">
<div className="w-12 h-12 bg-gray-800 rounded-lg flex items-center justify-center">
<div className="text-white">閻</div>
</div>
<div className="w-12 h-12 bg-gray-800 rounded-lg flex items-center justify-center bg-[url('/image/icon.png')] bg-contain" />
<div className="flex-grow">
<h1 className="text-white text-2xl font-bold">閻魔帳</h1>
<p className="text-gray-300 text-xs">v2 &quot;medusa&quot; - @sweshelo</p>
Expand Down
7 changes: 7 additions & 0 deletions src/components/revalidater/action.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
'use server'

import { revalidateTag } from 'next/cache'

export const revalidateUserData = async (user: string) => {
revalidateTag(user)
}
17 changes: 17 additions & 0 deletions src/components/revalidater/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
'use client'

import { revalidateUserData } from './action'

interface Props {
player: string
}

export const Revalidater = ({ player }: Props) => {
return (
<div className="p-[3px] rounded-lg bg-green-300 shadow mt-4 outline outline-1 outline-green-500">
<button className="w-full text-center" onClick={() => revalidateUserData(player)}>
最新の状態に更新する
</button>
</div>
)
}
Loading
Loading