Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
cotyhamilton committed May 5, 2024
1 parent a2892fc commit c5d1c44
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 7 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ example implementation: https://github.com/cotyhamilton/deno-auth-lucia

```sh
deno add @cotyhamilton/lucia-adapter-denokv
deno add npm:lucia@3
```

```ts
import { Lucia } from "npm:lucia@3";
import { Lucia } from "lucia";
import { DenoKVAdapter } from "@cotyhamilton/lucia-adapter-denokv";

const kv = await Deno.openKv();
Expand All @@ -25,7 +26,7 @@ export const lucia = new Lucia(new DenoKVAdapter(kv), {
},
});

declare module "npm:lucia" {
declare module "lucia" {
interface Register {
Lucia: typeof lucia;
DatabaseUserAttributes: DatabaseUserAttributes;
Expand Down
2 changes: 1 addition & 1 deletion deno.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cotyhamilton/lucia-adapter-denokv",
"version": "0.1.1",
"version": "0.1.2",
"exports": "./mod.ts",
"exclude": [".github", ".vscode", "coverage", "docs", "deno.lock"],
"tasks": {
Expand Down
24 changes: 22 additions & 2 deletions deno.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions mod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ type User = { id: string };

/**
* ```ts
* import { Lucia } from "npm:lucia@3";
* import { Lucia } from "lucia";
* import { DenoKVAdapter } from "@cotyhamilton/lucia-adapter-denokv";
*
* const kv = await Deno.openKv();
Expand All @@ -19,7 +19,7 @@ type User = { id: string };
* },
* });
*
* declare module "npm:lucia" {
* declare module "lucia" {
* interface Register {
* Lucia: typeof lucia;
* DatabaseUserAttributes: DatabaseUserAttributes;
Expand Down

0 comments on commit c5d1c44

Please sign in to comment.