Monorepo Structure
π Structure
/aquarium-game
βββ /backend # Backend with Node.js + Express
β βββ /src
β β βββ /controllers # Business logic (management of users, aquariums, marketplace)
β β βββ /models # Database models (Fish, Users, Transactions)
β β βββ /routes # API routes (REST Endpoints)
β β βββ /services # Connection to blockchain and contract logic
β β βββ /utils # Helpers and auxiliary functions
β β βββ app.ts # Server configuration Express
β βββ package.json # Backend dependencies
β βββ tsconfig.json # TypeScript configuration
β
βββ /frontend # Frontend with React + Next.js
β βββ /public # Images, fonts, icons
β βββ /src
β β βββ /app # Next.js main pages
β β βββ /components # Reusable components (Aquarium, PezCard, Marketplace, etc.)
β β βββ /context # Global state with React Context
β β βββ /hooks # Custom hooks for logic specific
β β βββ /services # Connection to backend and blockchain
β β βββ /styles # Style files (TailwindCSS)
β β βββ /utils # Helper functions
β β βββ /assets # Sprites, images, decorations
β βββ next.config.js # Next.js configuration
β βββ package.json # Frontend dependencies
β βββ tsconfig.json # TypeScript configuration
β
βββ /smart-contracts # Smart contracts in Cairo
β βββ /contracts # Contracts code (Fish, Marketplace, Evolution)
β βββ /tests # Testing contracts in Cairo
β βββ compile.sh # Script to compile the contracts
β βββ deploy.sh # Script to deploy to StarkNet
β βββ README.md # Documentation about smart contracts
β
βββ .github # CI/CD configuration (optional)
βββ .env # Environment variables
βββ README.md # General project documentationπ₯ Why Use a Monorepo?
Last updated