- π Overview
- π¦ Features
- π Structure
- π» Installation
- ποΈ Usage
- π Hosting
- π License
- π Authors
This repository houses the Minimum Viable Product (MVP) for a fitness goal tracker web application. The application aims to provide users with a platform to:
- Set personalized fitness goals
- Track their progress
- Share achievements with their friends
The MVP is built using a modern tech stack, including:
- React for the user interface
- TypeScript for strong typing and code maintainability
- Next.js for server-side rendering and static site generation
- PostgreSQL for a robust and scalable database
- Tailwind CSS for rapid prototyping and styling
- Zustand for simple and efficient state management
- Prisma ORM for easy database interactions
- NextAuth.js for secure user authentication
- Sentry for comprehensive error tracking and monitoring
Feature | Description |
---|---|
Goal Setting | Users can create and customize their fitness goals with specific targets, deadlines, and tracking parameters. |
Progress Tracking | Users can monitor their progress towards goals by logging weight, exercise sessions, and other relevant data. |
Social Sharing | Users can connect with friends and share their achievements, providing encouragement and fostering a supportive community. |
Data Visualization | Visualizations (e.g., graphs, charts) offer insights into progress trends, motivating users to stay on track. |
User-Friendly Interface | The application is designed with a clear and intuitive user interface for ease of navigation and interaction. |
Third-Party Integrations | The application can integrate with popular fitness trackers and wearable devices for automated data capture. |
Secure User Data | Robust security measures protect user data, ensuring privacy and confidentiality. |
Scalability | The application is built with scalability in mind, capable of handling a growing user base and data volume. |
Regular Updates | The application will receive regular updates based on user feedback and industry trends. |
fitness-goal-tracker/
βββ pages
β βββ api
β β βββ auth
β β βββ [...nextauth].js
β βββ _app.tsx
β βββ index.tsx
β βββ goals
β β βββ page.tsx
β βββ dashboard
β βββ page.tsx
βββ components
β βββ GoalCard.tsx
β βββ GoalForm.tsx
β βββ GoalList.tsx
β βββ Header.tsx
β βββ Layout.tsx
β βββ Sidebar.tsx
β βββ SocialFeed.tsx
β βββ Profile.tsx
β βββ InputField.tsx
βββ styles
β βββ globals.css
βββ prisma
β βββ migrations
β β βββ 20231120115405_init
β β βββ migration.sql
β βββ schema.prisma
βββ utils
β βββ helpers.js
β βββ index.js
βββ .eslintrc.js
βββ next.config.mjs
βββ tailwind.config.js
βββ tsconfig.json
βββ postcss.config.mjs
βββ package.json
- Node.js
- npm
- Docker (Optional for database setup)
- Clone the repository:
git clone https://github.com/spectra-ai-codegen/project-1723912636967-e4sw0b.git
- Navigate to the project directory:
cd project-1723912636967-e4sw0b
- Install dependencies:
npm install
- Setup the database:
- Option 1 (Docker):
docker-compose up -d
- Option 2 (Local PostgreSQL):
- Install PostgreSQL locally
- Create a new database
- Configure database credentials in
.env
file
- Option 1 (Docker):
- Run database migrations:
npx prisma db push
- Start the development server:
npm run dev
- Open your browser and navigate to http://localhost:3000.
Adjust configuration settings in next.config.mjs
or .env
files as needed.
- Goal Creation: Create a new fitness goal with a specific target, deadline, and tracking parameters.
- Progress Logging: Log your weight, exercise sessions, and other data to track progress towards goals.
- Social Sharing: Connect with friends, share your achievements, and provide encouragement.
- Data Visualization: Explore data visualizations (e.g., graphs, charts) to gain insights into your progress trends.
- Create a new Vercel project.
- Connect the repository to Vercel.
- Deploy the application using Vercel's deployment tools.
- Create a new Netlify site.
- Connect the repository to Netlify.
- Deploy the application using Netlify's deployment tools.
- Install the Heroku CLI:
npm install -g heroku
- Login to Heroku:
heroku login
- Create a new Heroku app:
heroku create
- Configure environment variables (DB_HOST, DB_USER, DB_PASS) in Heroku.
- Deploy the code:
git push heroku main
NEXT_PUBLIC_APP_NAME
: The name of your application (e.g., "Fitness Goal Tracker")NEXTAUTH_URL
: Your application's URL (e.g., "http://localhost:3000")NEXTAUTH_SECRET
: A secret key for securing authentication (generate usingopenssl rand -base64 32
)DATABASE_URL
: The URL of your PostgreSQL database (e.g.,postgresql://user:password@host:port/database
)SENTRY_DSN
: Your Sentry DSN for error tracking (optional)
This application is licensed under the MIT License.
- Author Name - Spectra.codes
- Creator Name - DRIX10
Why only generate Code? When you can generate the whole Repository!