A simple, fast and secure Contactory management application that helps users organize all their personal and professional/ contacts in one place.
π Live Demo
| Feature | Status | Description |
|---|---|---|
| Authentication | β Implemented | Secure signup, signin, password reset and session management |
| Theme Support | π§ In Progress | Dark/light mode with system preference detection |
| Organize Contacts | π Coming Soon | CRUD operations for contacts |
| Search & Filter | π Coming Soon | Real-time search with advanced filtering |
| Sync | π Coming Soon | Cross-device synchronization |
| Share | π Coming Soon | Share contacts via link, email or messaging |
| Import/Export | π Coming Soon | CSV, vCard and JSON support |
| Groups/Labels | π Coming Soon | Custom groups with color coding |
| Favorites | π Coming Soon | Quick access to important contacts |
| Duplicate Detection | π Coming Soon | Find and merge duplicate contacts |
| QR Code Sharing | π Coming Soon | Share contact info via scannable QR code |
| Internationalization | π Coming Soon | Bilingual support (English/Arabic) with RTL/LTR layout |
| Technology | Purpose |
|---|---|
| TypeScript | Type-safe JavaScript |
| Vite | Build tool & dev server |
| TanStack Start | Full-stack React framework |
| React 19 | UI library |
| Technology | Purpose |
|---|---|
| TanStack Router | Type-safe routing |
| TanStack Query | Data fetching & caching |
| TanStack Store | State management |
| TanStack Form | Form handling |
| Drizzle ORM | Database ORM (PostgreSQL) |
| Zod | Schema validation |
| Technology | Purpose |
|---|---|
| Tailwind CSS 4 | Utility-first styling |
| shadcn/ui | Component library |
| Radix UI | Accessible primitives |
| Lucide React | Icons |
| Sonner | Toast notifications |
| next-themes | Theme management |
| CVA | Component variants |
| Technology | Purpose |
|---|---|
| better-auth | Auth library |
| Technology | Purpose |
|---|---|
| Vitest | Unit testing |
| Testing Library | Component testing |
| ESLint | Linting |
| Prettier | Code formatting |
contactory/
βββ .github/ # GitHub configuration
β βββ copilot-instructions.md # Copilot code generation guidelines
β βββ git-commit-instructions.md # Commit message conventions
β βββ workflows/
β βββ ci.yml # CI/CD pipeline configuration
βββ docs/ # Documentation
β βββ ADR-001-tech-stack.md # Architecture decision record
β βββ PRD.md # Product requirements document
βββ drizzle/ # Database migrations
β βββ meta/ # Migration metadata
βββ public/ # Static assets
β βββ favicon.svg
β βββ manifest.json
β βββ robots.txt
βββ src/
β βββ db/ # Database configuration
β β βββ index.ts # Database client
β β βββ schemas/ # Drizzle ORM schemas
β β βββ auth.ts # Auth-related tables
β β βββ contacts.ts # Contact tables
β βββ features/ # Feature modules
β β βββ abstractions/ # Shared UI components
β β β βββ components/
β β β β βββ primitives/ # Base UI components (button, input, etc.)
β β β β βββ reused/ # Composite components (header, footer, etc.)
β β β βββ lib/ # Utility functions
β β β βββ storage.ts # cn() and helpers
β β β βββ utils.test.ts # Unit tests
β β βββ users/ # User feature module
β β βββ components/ # Auth forms
β β βββ functions/ # Server functions
β βββ integrations/ # Third-party integrations
β β βββ better-auth/ # Auth integration
β β β βββ auth.ts # Server auth config
β β β βββ auth-client.ts # Client auth config
β β β βββ hooks/ # Auth mutations
β β β βββ middlewares/ # Auth middlewares
β β βββ tanstack-form/ # Form integration
β β β βββ components/ # Form field components
β β β βββ hooks/ # useAppForm hook
β β βββ tanstack-query/ # Query integration
β β βββ root-provider.tsx # Query client provider
β β βββ devtools.tsx # Query devtools
β βββ routes/ # TanStack Router routes
β β βββ __root.tsx # Root layout
β β βββ index.tsx # Home page
β β βββ _auth/ # Auth layout routes
β β β βββ signin.tsx
β β β βββ signup.tsx
β β β βββ forgot-password.tsx
β β β βββ reset-password.tsx
β β βββ api/auth/ # Auth API routes
β β βββ console/ # Protected routes
β βββ env.ts # Type-safe environment variables
β βββ router.tsx # Router configuration
β βββ routeTree.gen.ts # Auto-generated route tree
β βββ styles.css # Global styles
βββ components.json # shadcn/ui config
βββ drizzle.config.ts # Drizzle ORM config
βββ eslint.config.js # ESLint config
βββ package.json # Dependencies & scripts
βββ prettier.config.js # Prettier config
βββ tsconfig.json # TypeScript config
βββ vite.config.ts # Vite config
- Node.js 20+
- pnpm 9+
- PostgreSQL database
# Clone the repository
git clone https://github.com/your-username/contactory.git
cd contactory
# Install dependencies
pnpm installCopy the example environment file and configure your variables:
cp .env.example .env.localThen fill in the required environment variables:
| Variable | Description | Required |
|---|---|---|
DATABASE_URL |
PostgreSQL connection string | β |
BETTER_AUTH_SECRET |
Secret key for authentication | β |
BETTER_AUTH_URL |
Base URL of your app (e.g., http://localhost:3000) |
β |
BETTER_AUTH_ENABLE_OPENAPI |
Enable OpenAPI docs (true for dev, false for prod) |
β |
VITE_BETTER_AUTH_BASE_URL |
Client-side base URL of your app | β |
# Run database migrations
pnpm db:migrate
# Start the development server
pnpm devThe app will be running at http://localhost:3000.
| Script | Description |
|---|---|
pnpm dev |
Start development server (port 3000) |
pnpm build |
Build for production |
pnpm serve |
Preview production build |
pnpm test |
Run unit tests |
pnpm lint |
Lint codebase |
pnpm format |
Format code with Prettier |
pnpm check |
Format and lint with auto-fix |
pnpm typecheck |
Run TypeScript type checking |
pnpm db:generate |
Generate database migrations |
pnpm db:migrate |
Run database migrations |
pnpm db:push |
Push schema changes to database |
pnpm db:studio |
Open Drizzle Studio |
| Document | Description |
|---|---|
| Product Requirements (PRD) | Feature specifications, user stories and requirements |
| Tech Stack ADR | Architecture decision record explaining technology choices |
| File | Description |
|---|---|
| Copilot Instructions | Code generation guidelines and project conventions for GitHub Copilot |
| Git Commit Instructions | Conventional commit message format and guidelines |
| CI Workflow | GitHub Actions workflow for linting, testing and building |
The project uses GitHub Actions for continuous integration. The pipeline runs on every push and pull request to main:
- Linting β ESLint code quality checks
- Formatting β Prettier format verification
- Type Check β TypeScript type validation
- Tests β Vitest unit test execution
- Build β Production build verification
| Package | Version | Description |
|---|---|---|
react |
^19.2.1 | UI library |
react-dom |
^19.2.1 | React DOM renderer |
@tanstack/react-start |
^1.132.0 | Full-stack React framework |
@tanstack/react-router |
^1.132.0 | Type-safe routing |
@tanstack/react-query |
^5.66.5 | Data fetching & caching |
@tanstack/react-form |
^1.0.0 | Form handling |
@tanstack/react-store |
^0.7.0 | State management |
drizzle-orm |
^0.39.0 | Database ORM |
pg |
^8.11.0 | PostgreSQL client |
better-auth |
^1.4.5 | Authentication library |
zod |
^4.1.11 | Schema validation |
tailwindcss |
^4.0.6 | CSS framework |
class-variance-authority |
^0.7.1 | Component variants |
clsx |
^2.1.1 | Class name utility |
tailwind-merge |
^3.0.2 | Tailwind class merging |
@radix-ui/* |
various | Accessible UI primitives |
lucide-react |
^0.544.0 | Icon library |
sonner |
^2.0.7 | Toast notifications |
next-themes |
^0.4.6 | Theme management |
@t3-oss/env-core |
^0.13.8 | Type-safe env variables |
uuid |
^13.0.0 | UUID generation |
| Package | Version | Description |
|---|---|---|
typescript |
^5.7.2 | TypeScript compiler |
vite |
^7.1.7 | Build tool |
vitest |
^3.0.5 | Test runner |
@testing-library/react |
^16.2.0 | Component testing |
eslint |
^9.39.1 | Linting |
prettier |
^3.5.3 | Code formatting |
drizzle-kit |
^0.30.0 | Drizzle CLI tools |
@netlify/vite-plugin-tanstack-start |
^1.2.2 | Netlify deployment |
This project is private.