Linky is a URL shortener service that allows you to shorten long URLs into short links. View Demo
- Shorten long URLs into short links
- Authentication with NextAuth.js with Github
- View all links created by a user in the dashboard
- Short links statistics (clicks,browser,os)
- Next.js
- Tailwind CSS
- TypeScript
- Turso (Sqlite database)
- Vitest (Testing library)
First, clone the repository:
git clone https://github.com/Carlos0934/linky.git linkyThen, navigate to the project directory:
cd linkyInstall the dependencies:
npm install Create a .env.local file in the root of the project and add the following environment variables:
DATABASE_URL=<your_database_url>
DATABASE_AUTH_TOKEN=<your_auth_token>
BASE_URL=http://localhost:3000
GITHUB_APP_CLIENT_ID=<your_github_app_client_id>
GITHUB_APP_CLIENT_SECRET=<your_github_app_client_secret>
NEXTAUTH_SECRET=<your_nextauth_secret>Create database migrations:
npm run generateRun the migrations:
npm run migrateStart the development server:
npm run devOpen http://localhost:3000 in your browser.
Run the tests:
npm run test
