Timify is a standard Next.js application with a local SQLite database — no Docker, no external services, and no cloud accounts required. Follow the steps below to go from zero to a running timer in under five minutes.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Aking16/timify/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Before you begin, make sure the following tools are available on your machine:- Node.js 18 or later (20 LTS recommended)
- Git
- A package manager: npm (bundled with Node.js), pnpm, or yarn
Setup Steps
DB_FILE_NAME=file:./src/db/local.db
BETTER_AUTH_SECRET=your-secret-here
BETTER_AUTH_URL=http://localhost:3000
The
DB_FILE_NAME path is relative to the project root and tells both Drizzle and the libsql client where to create the SQLite database file. The file is created automatically when you push the schema in the next step — no manual setup required.BETTER_AUTH_SECRET must be a long, randomly generated string. You can generate one with:Drizzle’s
push command introspects src/db/schema.ts and applies all table definitions directly to the SQLite file — no migration files are written during local development with this command.You should see output confirming that each table (
user, session, account, verification, projects, time_entries, tags, time_entry_tags) was created successfully.To visually inspect your database at any time, run
npx drizzle-kit studio and open the URL it prints. This launches the Drizzle Studio UI in your browser.Next.js will start on http://localhost:3000 by default.
Navigate to http://localhost:3000 in your browser. You will be redirected to
/auth to register a new account. Once signed in:Available Commands
| Command | Description |
|---|---|
npm run dev | Start the Next.js development server with hot reload |
npm run build | Create an optimised production build |
npm run start | Run the production build locally |
npm run lint | Run ESLint (flat config via eslint.config.mjs) |
npx drizzle-kit push | Push schema changes to the SQLite database |
npx drizzle-kit studio | Open Drizzle Studio database viewer |
Troubleshooting
The app redirects me to /auth but registration fails
The app redirects me to /auth but registration fails
Check that
BETTER_AUTH_SECRET and BETTER_AUTH_URL are set in your .env file and that the URL exactly matches the origin your browser is using (e.g. http://localhost:3000). The trustedOrigins list in src/lib/auth.ts must include your origin.drizzle-kit push reports a missing DB_FILE_NAME
drizzle-kit push reports a missing DB_FILE_NAME
Ensure your
.env file is in the project root (the same directory as package.json) and that the value uses the file: prefix, for example file:./src/db/local.db.I see a React Compiler warning in the console
I see a React Compiler warning in the console
Timify enables the React Compiler via
reactCompiler: true in next.config.ts. Do not add manual useMemo or useCallback calls — the compiler handles memoisation automatically. Suppressing compiler warnings by disabling it is not recommended.