An open API service indexing awesome lists of open source software.

https://github.com/aidan-neel/sveltekit-auth

SvelteKit template using my library PrismaAuth.js to handle registration. Uses Prisma, and SQLite3(changeable) for data storing. Comes with login, registration, and a sign-out page built with Shadcn-svelte.
https://github.com/aidan-neel/sveltekit-auth

authentication authorization prisma sql sqlite3 sveltekit template

Last synced: 10 months ago
JSON representation

SvelteKit template using my library PrismaAuth.js to handle registration. Uses Prisma, and SQLite3(changeable) for data storing. Comes with login, registration, and a sign-out page built with Shadcn-svelte.

Awesome Lists containing this project

README

          

# SvelteKit Authentication Template
Built with [Prisma](https://github.com/prisma/prisma), [PrismaAuth.js](https://github.com/aidan-neel/PrismaAuth.js), [SvelteKit](https://github.com/sveltejs/kit), [shadcn-svelte](https://github.com/huntabyte/shadcn-svelte), and more.

## Configuration
**1.** Set the random JWT token key in the .env file in the root directory like so:
```javascript
DATABASE_URL="file:./dev.db"
JWT_SECRET="RANDOMLY_GENERATED_STRING"
```

**3.** Inside the *src/lib/isDev.ts* file change the url to the appropriate domain like so:
```javascript
export let url = isDev ? 'http://localhost:5173' : 'https://url.com'; // Change this to your own url
```

## Notes
**1.** The database is interchangeable. You can use SQLite3, MySQL, PostgreSQL with Vercel, etc. As long as Prisma supports it, the template supports it.