-
-
Notifications
You must be signed in to change notification settings - Fork 0
📝 add claude.md #364
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
📝 add claude.md #364
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,70 @@ | ||||||||||||||||||
| # CLAUDE.md | ||||||||||||||||||
|
|
||||||||||||||||||
| This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. | ||||||||||||||||||
|
|
||||||||||||||||||
| ## Commands | ||||||||||||||||||
|
|
||||||||||||||||||
| ```bash | ||||||||||||||||||
| # Development | ||||||||||||||||||
| pnpm dev # Start dev server with Turbopack | ||||||||||||||||||
| pnpm build # Build all packages | ||||||||||||||||||
| pnpm type-check # Run TypeScript checks | ||||||||||||||||||
|
|
||||||||||||||||||
| # Run commands for specific app | ||||||||||||||||||
| pnpm --filter @onruntime/web dev | ||||||||||||||||||
| pnpm --filter @onruntime/web build | ||||||||||||||||||
| ``` | ||||||||||||||||||
|
|
||||||||||||||||||
| ## Architecture | ||||||||||||||||||
|
|
||||||||||||||||||
| ### Monorepo Structure (Turborepo + pnpm workspaces) | ||||||||||||||||||
|
|
||||||||||||||||||
| ``` | ||||||||||||||||||
| / | ||||||||||||||||||
| ├── apps/ | ||||||||||||||||||
| │ └── web/ # Next.js 16 website (@onruntime/web) | ||||||||||||||||||
| ├── packages/ # Shared packages (future) | ||||||||||||||||||
| ├── turbo.json # Turborepo configuration | ||||||||||||||||||
| └── pnpm-workspace.yaml # pnpm workspace config | ||||||||||||||||||
| ``` | ||||||||||||||||||
|
Comment on lines
+22
to
+29
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add language specifier to the directory tree code block. The fenced code block showing the monorepo structure is missing a language identifier, which markdown linters require for best practices. 🔎 Proposed fix-```
+```text
/
├── apps/
│ └── web/ # Next.js 16 website (@onruntime/web)
├── packages/ # Shared packages (future)
├── turbo.json # Turborepo configuration
└── pnpm-workspace.yaml # pnpm workspace config
-```
+```📝 Committable suggestion
Suggested change
🧰 Tools🪛 markdownlint-cli2 (0.18.1)22-22: Fenced code blocks should have a language specified (MD040, fenced-code-language) 🤖 Prompt for AI Agents |
||||||||||||||||||
|
|
||||||||||||||||||
| ### Web App Structure (`apps/web/src/`) | ||||||||||||||||||
|
|
||||||||||||||||||
| - **app/**: Next.js App Router pages and API routes | ||||||||||||||||||
| - **components/**: React components (ui/, layout/, marketing/) | ||||||||||||||||||
| - **services/**: External API clients with lazy initialization | ||||||||||||||||||
| - **constants/**: Static data (projects, agencies, services, team members) | ||||||||||||||||||
| - **content/**: MDX content (glossary, legal pages) | ||||||||||||||||||
| - **lib/**: Utilities and helpers | ||||||||||||||||||
| - **types/**: TypeScript type definitions | ||||||||||||||||||
|
Comment on lines
+33
to
+39
|
||||||||||||||||||
|
|
||||||||||||||||||
| ### Key Patterns | ||||||||||||||||||
|
|
||||||||||||||||||
| **Services**: Use lazy initialization for external API clients to avoid build failures when env vars are missing in CI: | ||||||||||||||||||
| ```typescript | ||||||||||||||||||
| // services/email.ts - Proxy pattern for lazy init | ||||||||||||||||||
| export const resend = new Proxy({} as Resend, { | ||||||||||||||||||
| get(_, prop) { | ||||||||||||||||||
| if (!instance) { | ||||||||||||||||||
|
||||||||||||||||||
| if (!instance) { | |
| if (!instance) { | |
| // Note: The real implementation checks that env.RESEND_API_KEY is defined | |
| // before creating the Resend instance; this example omits that error handling | |
| // for brevity. |
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| import createMDX from "@next/mdx"; | ||
| import type { NextConfig } from "next"; | ||
| import "./env"; | ||
|
|
||
| const nextConfig: NextConfig = { | ||
| pageExtensions: ["ts", "tsx", "js", "jsx", "md", "mdx"], | ||
| reactStrictMode: process.env.NODE_ENV === "development", | ||
| transpilePackages: ["next-seo"], | ||
| env: { | ||
| NEXT_PUBLIC_NODE_ENV: process.env.NODE_ENV, | ||
| }, | ||
| webpack(config) { | ||
| config.module.rules.push({ | ||
| test: /\.svg$/i, | ||
| use: ["@svgr/webpack"], | ||
| }); | ||
| return config; | ||
| }, | ||
| async redirects() { | ||
| return [ | ||
| { | ||
| source: "/projects/instagram-dark/welcome", | ||
| destination: "/projects/dark-theme-instagram", | ||
| permanent: true, | ||
| }, | ||
| { | ||
| source: "/projects/instagram-dark", | ||
| destination: "/projects/dark-theme-instagram", | ||
| permanent: true, | ||
| }, | ||
| { | ||
| source: "/about", | ||
| destination: "/npo", | ||
| permanent: false, | ||
| }, | ||
| ]; | ||
| }, | ||
| }; | ||
|
|
||
| const withMDX = createMDX({ | ||
| extension: /\.mdx?$/, | ||
| }); | ||
|
|
||
| export default withMDX(nextConfig); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The documentation states that there is a
packages/directory for shared packages with the comment "(future)", but this directory does not currently exist in the repository. This could be misleading to someone using this documentation. Consider either removing this line entirely or making it clearer that this is a planned directory structure that doesn't exist yet (e.g., "packages/ (planned)" or removing it until the directory is actually created).