-
Couldn't load subscription status.
- Fork 12
[cookbook] Migrate to pnpm workspace monorepo #89
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains a major architectural refactoring that migrates the GenAI Cookbook from npm to a pnpm workspace monorepo structure. The changes include significant code cleanup, removal of technical debt, performance improvements, and bug fixes. The result is a more maintainable, performant, and scalable codebase with ~2,100 fewer lines of code.
Key Changes
🏗️ Architecture & Structure
Migrated to pnpm workspace monorepo
apps/andpackages/directoriespnpm-workspace.yamlconfigurationpackage-lock.json, addedpnpm-lock.yamlRestructured codebase into monorepo
apps/cookbook/- Next.js 14 application with App Routerpackages/recipes/- Shared recipe implementations (UI + API)🧹 Code Refactoring & Cleanup
Removed useCookbook from recipe UI components
Added general-purpose cache utility (
apps/cookbook/utils/cache.ts)Simplified recipe API handlers (apps/cookbook/app/cookbook/[recipe]/api/route.ts:1)
Moved theme into cookbook app (apps/cookbook/utils/theme.ts:1)
🐛 Bug Fixes & Improvements
Migration Notes
For Developers
If you're pulling this branch, you'll need to:
Install pnpm (if not already installed):
Remove old dependencies:
Install dependencies:
Run development server:
Statistics
🤖 Generated with Claude Code
Co-Authored-By: Claude noreply@anthropic.com