This is a simple Habit Tracker application built with SvelteKit and TypeScript. It allows users to track their habits daily, weekly, or monthly. The project includes progress visualization, habit completion, and a minimalist UI to manage and view habits.
habit-tracker/
├── public/ # Public assets (favicon, images)
├── src/
│ ├── app.d.ts # Type definitions for SvelteKit
│ ├── routes/ # SvelteKit pages
│ │ ├── +layout.svelte # Global layout
│ │ ├── +page.svelte # Main dashboard page for habits
│ │ └── habits/
│ │ ├── +page.svelte # Page to add and manage habits
│ │ └── [id].svelte # Detail page for each habit
│ ├── lib/ # Library of reusable components and utilities
│ │ ├── components/
│ │ │ ├── HabitCard.svelte # Component for each habit display
│ │ │ └── HabitList.svelte # List of all habits
│ │ ├── styles/ # Global SCSS styles
│ │ ├── stores/ # Svelte stores for global state
│ │ │ └── habitsStore.ts # Store for managing habit data
│ │ └── utils/ # Utility functions
│ │ └── formatDate.ts # Function to format dates
│ └── app.html # Main HTML template
├── svelte.config.js # Svelte configuration
├── tsconfig.json # TypeScript configuration
├── vite.config.js # Vite configuration
└── package.json # Dependencies and scripts
Make sure you have Node.js installed.
Clone the repository:
git clone https://github.com/antoinegreuzard/habit-tracker.git
Navigate into the project directory:
cd habit-tracker
Install dependencies:
pnpm install
Start the development server:
pnpm dev
The app will be available at http://localhost:5173
.
To build the project for production, run:
pnpm build
git checkout -b feature/YourFeature
).git commit -m 'Add some feature'
).git push origin feature/YourFeature
).This project is licensed under the MIT License.