Dugout Value
투구·타격·예측 연구와 선수·계약·트레이드 가치를 비교하는 도구 제공
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기TB site in NextJS
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
The web frontend for TrickBook — a social platform for action sports, by riders, for riders. Live at thetrickbook.com.
This is a Next.js app (Pages Router) that serves as both the marketing/content site and the user-facing web client for the TrickBook platform. All application data lives in the TrickBook backend API (api.thetrickbook.com); this app renders it, handles authentication via next-auth, and shares the same JWT auth strategy as the mobile app.README 전문 보기 ↗The web frontend for TrickBook — a social platform for action sports, by riders, for riders. Live at thetrickbook.com.
This is a Next.js app (Pages Router) that serves as both the marketing/content site and the user-facing web client for the TrickBook platform. All application data lives in the TrickBook backend API (api.thetrickbook.com); this app renders it, handles authentication via next-auth, and shares the same JWT auth strategy as the mobile app.
Feature areas (see pages/):
revalidate: 60) fetched from the backend blog API, with SEO metadata, table of contents, and share actions./trickipedia/[category])./trickbook/my-lists, /tricklist)./admin).@pixiv/three-vrm).flowchart TD
Browser[Browser] --> Next[Next.js app<br/>Pages Router, SSG/ISR]
Next --> AuthRoute["API route: /api/auth/[...nextauth]<br/>(next-auth v4)"]
AuthRoute --> Credentials[Credentials provider]
AuthRoute --> Google[Google provider]
AuthRoute --> Apple[Apple provider]
Credentials --> API[TrickBook Backend API<br/>api.thetrickbook.com]
Google --> API
Apple --> API
Next --> API
Next -- Socket.io --> API
Next -- media playback --> CDN[Bunny CDN / S3]
GitHub[GitHub main branch] -- amplify.yml --> Amplify[AWS Amplify<br/>build & deploy]
Amplify --> Next
Key points:
pages/api/auth/[...nextauth].js). All other data access goes straight to the Express backend through the lib/api*.js client modules./api/auth/google-auth, /api/auth/apple-auth), which returns the platform JWT stored on the next-auth session — the same JWT scheme the mobile app uses.getStaticProps/getStaticPaths with 60-second ISR revalidation.| Concern | Technology |
|---|---|
| Framework | Next.js 13.5 (Pages Router), React 18.2 |
| Auth | next-auth 4.24 (Credentials, Google, Apple providers) |
| Styling | Tailwind CSS 3.4 + MUI 5 (transitioning to Tailwind-first), Radix UI primitives, next-themes for dark mode |
| Data fetching | axios clients in lib/ against the Express backend |
| Real-time | socket.io-client |
| Maps | @vis.gl/react-google-maps + @googlemaps/markerclusterer |
| Video | Bunny Stream (HLS via hls.js, tus-js-client uploads) |
| Payments | Stripe (@stripe/stripe-js) |
| Analytics | PostHog, Google Analytics (@next/third-parties) |
| 3D | three.js + @pixiv/three-vrm (Kaori Live) |
| Lint/format | Biome (+ husky/lint-staged pre-commit hooks) |
| Testing | Playwright |
Prerequisites: Node 20 (see .nvmrc; engines requires >=20).
nvm use # picks up Node 20 from .nvmrc
npm install
cp .env.example .env.local # then fill in values (see below)
npm run dev # http://localhost:3000
The app expects the TrickBook backend running locally on port 9000 (or point NEXT_PUBLIC_BASE_URL / NEXT_PUBLIC_API_BASE_URL at another environment).
Names and purpose only — never commit real values. .env.local is gitignored; production values are managed in the AWS Amplify console (the Amplify build writes the allow-listed vars into .env.production during preBuild).
| Variable | Purpose |
|---|---|
BASE_URL / NEXT_PUBLIC_BASE_URL | Backend API origin (e.g. local Express server or https://api.thetrickbook.com) |
NEXT_PUBLIC_API_BASE_URL | Backend API base path (<origin>/api) |
NEXTAUTH_URL | Canonical URL for next-auth callbacks |
NEXTAUTH_SECRET | next-auth session/JWT encryption secret |
JWT_SECRET | Shared JWT signing secret (must match backend) |
GOOGLE_CLIENT_ID / GOOGLE_CLIENT_SECRET | Google OAuth provider |
APPLE_WEB_SERVICE_ID | Apple SSO Services ID (client ID for Sign in with Apple on web) |
APPLE_TEAM_ID / APPLE_KEY_ID / APPLE_PRIVATE_KEY | Used to mint the Apple client secret (ES256 JWT) at runtime |
NEXT_PUBLIC_GOOGLE_MAPS_KEY | Google Maps JS API key (spots map) |
NEXT_PUBLIC_BUNNY_LIBRARY_ID / NEXT_PUBLIC_BUNNY_CDN_HOSTNAME | Bunny Stream playback (public values) |
NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY | Stripe publishable key |
NEXT_PUBLIC_POSTHOG_KEY / NEXT_PUBLIC_POSTHOG_HOST | PostHog analytics |
NEXT_PUBLIC_GA_MEASUREMENT_ID | Google Analytics measurement ID |
NEXT_PUBLIC_KITH_VOICE_WS_URL | Kaori voice-service WebSocket URL |
See .env.example for the full documented template.
| Script | What it does |
|---|---|
npm run dev | Start the dev server |
npm run build | Production build (next build) |
npm start | Serve the production build |
npm run lint / npm run lint:fix | Biome check (read-only / auto-fix) |
npm run format / npm run format:check | Biome formatting |
npm run validate | Biome check + production build (CI-style gate) |
npm test | Jest unit tests for the pure helpers in lib/ |
npm run test:blog-smoke | Playwright blog smoke test |
Husky + lint-staged run Biome on staged files before every commit.
Blog content is API-backed, not file-backed: posts live in the backend database and are fetched through lib/api.js (https://api.thetrickbook.com/api/blog), then statically rendered with 60-second ISR. To publish or edit a post, use the admin dashboard (/admin/create-blog-post, /admin/blog) as an admin user.
The markdown files in posts/ (read by lib/posts.js via gray-matter) are a legacy/local content path that is no longer wired into the blog pages — treat them as source-of-record drafts, not the publishing mechanism.
Unit tests live next to the code in lib/__tests__/ and run with npm test (Jest through next/jest, no browser, no API). Add one whenever a helper in lib/ gains a branch worth keeping.
Playwright smoke tests live in tests/ (playwright.config.js):
npm run test:blog-smoke
The config auto-boots the dev server on 127.0.0.1:3000 (reusing an existing one) and runs against Desktop Chrome. The blog smoke test asserts heading structure, image alt text, table-of-contents rendering, and visible focus styles on a live blog post.
main branch to thetrickbook.com.amplify.yml — preBuild writes the allow-listed env vars (NEXT_PUBLIC_*, next-auth, Google/Apple OAuth, JWT) into .env.production, installs with npm install --legacy-peer-deps --ignore-scripts, then runs npm run build; artifacts are served from .next with node_modules and .next/cache cached between builds.| Repo | Purpose |
|---|---|
| wbaxterh/TrickBookFrontend | Mobile app (React Native / Expo) |
| wbaxterh/TB-Backend | Backend API (Express, MongoDB, Socket.io) |
| wbaxterh/TrickBookDocs | Documentation site (Docusaurus) |
Proprietary. Copyright © TrickBook. All rights reserved.