GithubHelp home page GithubHelp logo

paulzalele / lucia_auth Goto Github PK

View Code? Open in Web Editor NEW

This project forked from lucia-auth/lucia

0.0 0.0 0.0 5.34 MB

Authentication, simple and clean

Home Page: https://lucia-auth.com

License: MIT License

TypeScript 100.00%

lucia_auth's Introduction

Lucia

Lucia is a simple and flexible user and session management library that provides an abstraction layer between your app and your database. It's bare-bones by design, keeping everything easy to use and understand.

Code sample

Working with Lucia looks something like this. In the code below, you're creating a new user with an email/password method, creating a new session, and creating a cookie that you can set to the user.

const user = await auth.createUser({
	key: {
		providerId: "email",
		providerUserId: email,
		password
	},
	attributes: {
		email
	}
});
const session = await auth.createSession({
	userId: user.userId,
	attributes: {}
});
const sessionCookie = auth.createSessionCookie(session);

Resources

Documentation

Join the Discord server!

Examples

Contributing

Changelog

Installation

npm i lucia
pnpm add lucia
yarn add lucia

Attributions

This project would not have been possible without our contributors, thank you!

Logo by @dawidmachon, licensed under CC BY-NC-SA 4.0.

lucia_auth's People

Contributors

pilcrowonpaper avatar lucythecat avatar adriangonz97 avatar v-rogg avatar blastose avatar skepticmystic avatar dawidmachon avatar faeyumbrea avatar tazorde avatar gtim avatar jings avatar kazuumin avatar gustavocadev avatar ffss92 avatar jouandeag avatar machina20 avatar josefaidt avatar oscartbeaumont avatar ollema avatar schweden1997 avatar fredtreg avatar danawoodman avatar abdel-17 avatar parables avatar rafidmuhymin avatar rhenaldkarrel avatar simonsarris avatar sooditk avatar stewartside avatar diericx avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.