Skip to content

Commit

Permalink
Merge branch 'main' into docs/providers-to-source-code
Browse files Browse the repository at this point in the history
  • Loading branch information
balazsorban44 committed Apr 17, 2023
2 parents b0a8570 + e97b274 commit add9e1d
Show file tree
Hide file tree
Showing 9 changed files with 146 additions and 88 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ packages/*/*.d.ts.map
apps/dev/src/css
apps/dev/prisma/migrations
apps/dev/typeorm
apps/dev/nextjs-2

# VS
/.vs/slnx.sqlite-journal
Expand Down
10 changes: 3 additions & 7 deletions docs/docs/getting-started/databases.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,11 @@ title: Databases

Auth.js offers multiple database adapters. Check our guides on:

- [using a database adapter](/guides/adapters/using-a-database-adapter)
- [creating your own](/guides/adapters/creating-a-database-adapter)

> As of **v4** Auth.js no longer ships with an adapter included by default. If you would like to persist any information, you need to install one of the many available adapters yourself. See the individual adapter documentation pages for more details.
- [Using a database adapter](/guides/adapters/using-a-database-adapter)
- [Creating your own](/guides/adapters/creating-a-database-adapter)

To learn more about databases in Auth.js and how they are used, check out [databases in the FAQ](/concepts/faq#databases).

---

## How to use a database

See the [documentation for adapters](/reference/adapters/overview) for more information on advanced configuration, including how to use Auth.js with other databases using a [custom adapter](/guides/adapters/creating-a-database-adapter).
See the [documentation for adapters](/reference/adapters) for more information on advanced configuration, including how to use Auth.js with other databases using a [custom adapter](/guides/adapters/creating-a-database-adapter).
56 changes: 30 additions & 26 deletions docs/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -261,32 +261,36 @@ const docusaurusConfig = {
},
},
],
typedocAdapter("Dgraph"),
typedocAdapter("DynamoDB"),
typedocAdapter("Fauna"),
typedocAdapter("Firebase"),
typedocAdapter("Mikro ORM"),
typedocAdapter("MongoDB"),
typedocAdapter("Neo4j"),
typedocAdapter("PouchDB"),
typedocAdapter("Prisma"),
[
"docusaurus-plugin-typedoc",
{
...typedocConfig,
id: "typeorm",
plugin: [require.resolve("./typedoc-mdn-links")],
watch: process.env.TYPEDOC_WATCH,
entryPoints: [`../packages/adapter-typeorm-legacy/src/index.ts`],
tsconfig: `../packages/adapter-typeorm-legacy/tsconfig.json`,
out: `reference/adapter/typeorm`,
sidebar: { indexLabel: "TypeORM" },
},
],
typedocAdapter("Sequelize"),
typedocAdapter("Supabase"),
typedocAdapter("Upstash Redis"),
typedocAdapter("Xata"),
...(process.env.TYPEDOC_SKIP_ADAPTERS
? []
: [
typedocAdapter("Dgraph"),
typedocAdapter("DynamoDB"),
typedocAdapter("Fauna"),
typedocAdapter("Firebase"),
typedocAdapter("Mikro ORM"),
typedocAdapter("MongoDB"),
typedocAdapter("Neo4j"),
typedocAdapter("PouchDB"),
typedocAdapter("Prisma"),
[
"docusaurus-plugin-typedoc",
{
...typedocConfig,
id: "typeorm",
plugin: [require.resolve("./typedoc-mdn-links")],
watch: process.env.TYPEDOC_WATCH,
entryPoints: [`../packages/adapter-typeorm-legacy/src/index.ts`],
tsconfig: `../packages/adapter-typeorm-legacy/tsconfig.json`,
out: `reference/adapter/typeorm`,
sidebar: { indexLabel: "TypeORM" },
},
],
typedocAdapter("Sequelize"),
typedocAdapter("Supabase"),
typedocAdapter("Upstash Redis"),
typedocAdapter("Xata"),
]),
],
}

Expand Down
6 changes: 3 additions & 3 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@
"@docusaurus/theme-common": "2.3.1",
"@docusaurus/theme-mermaid": "2.3.1",
"@docusaurus/types": "2.3.1",
"docusaurus-plugin-typedoc": "1.0.0-next.2",
"typedoc": "^0.23.28",
"typedoc-plugin-markdown": "4.0.0-next.3"
"docusaurus-plugin-typedoc": "1.0.0-next.5",
"typedoc": "^0.24.4",
"typedoc-plugin-markdown": "4.0.0-next.6"
},
"browserslist": {
"production": [
Expand Down
46 changes: 25 additions & 21 deletions docs/sidebars.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,27 +46,31 @@ module.exports = {
},
],
},
{
type: "category",
label: "Database Adapters",
link: { type: "doc", id: "reference/adapters/index" },
items: [
{ type: "doc", id: "reference/adapter/dgraph/index" },
{ type: "doc", id: "reference/adapter/dynamodb/index" },
{ type: "doc", id: "reference/adapter/fauna/index" },
{ type: "doc", id: "reference/adapter/firebase/index" },
{ type: "doc", id: "reference/adapter/mikro-orm/index" },
{ type: "doc", id: "reference/adapter/mongodb/index" },
{ type: "doc", id: "reference/adapter/neo4j/index" },
{ type: "doc", id: "reference/adapter/pouchdb/index" },
{ type: "doc", id: "reference/adapter/prisma/index" },
{ type: "doc", id: "reference/adapter/sequelize/index" },
{ type: "doc", id: "reference/adapter/supabase/index" },
{ type: "doc", id: "reference/adapter/typeorm/index" },
{ type: "doc", id: "reference/adapter/upstash-redis/index" },
{ type: "doc", id: "reference/adapter/xata/index" },
],
},
...(process.env.TYPEDOC_SKIP_ADAPTERS
? []
: [
{
type: "category",
label: "Database Adapters",
link: { type: "doc", id: "reference/adapters/index" },
items: [
{ type: "doc", id: "reference/adapter/dgraph/index" },
{ type: "doc", id: "reference/adapter/dynamodb/index" },
{ type: "doc", id: "reference/adapter/fauna/index" },
{ type: "doc", id: "reference/adapter/firebase/index" },
{ type: "doc", id: "reference/adapter/mikro-orm/index" },
{ type: "doc", id: "reference/adapter/mongodb/index" },
{ type: "doc", id: "reference/adapter/neo4j/index" },
{ type: "doc", id: "reference/adapter/pouchdb/index" },
{ type: "doc", id: "reference/adapter/prisma/index" },
{ type: "doc", id: "reference/adapter/sequelize/index" },
{ type: "doc", id: "reference/adapter/supabase/index" },
{ type: "doc", id: "reference/adapter/typeorm/index" },
{ type: "doc", id: "reference/adapter/upstash-redis/index" },
{ type: "doc", id: "reference/adapter/xata/index" },
],
},
]),
"reference/warnings",
],
conceptsSidebar: [
Expand Down
5 changes: 3 additions & 2 deletions docs/typedoc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"excludeProtected": true,
"hideHierarchy": true,
"gitRevision": "main",
"groupByReflections": false,
"hideBreadcrumbs": true,
"hideGenerator": true,
"kindSortOrder": [
Expand Down Expand Up @@ -36,11 +37,11 @@
"SetSignature"
],
"readme": "none",
"reflectionsWithOwnFile": "none",
"sort": [
"kind",
"static-first",
"required-first",
"alphabetical"
],
"symbolsWithOwnFile": "none"
]
}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"dev-v4:db": "turbo run dev --parallel --continue --filter=next-auth-app-v4...",
"dev-v4": "turbo run dev --parallel --continue --filter=next-auth-app-v4... --filter=!./packages/adapter-*",
"dev:kit": "turbo run dev --parallel --continue --filter=sveltekit-auth-app...",
"dev:docs": "turbo run dev --filter=docs",
"dev:docs": "TYPEDOC_SKIP_ADAPTERS=1 turbo run dev --filter=docs",
"dev:docs:adapters": "turbo run dev --filter=docs",
"email": "cd apps/dev/nextjs && pnpm email",
"eslint": "eslint --cache .",
"lint": "prettier --check .",
Expand Down
4 changes: 2 additions & 2 deletions packages/next-auth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ This is a monorepo containing the following packages / projects:
## Getting Started

```
npm install --save next-auth
npm install next-auth
```

The easiest way to continue getting started, is to follow the [getting started](https://next-auth.js.org/getting-started/example) section in our docs.
Expand Down Expand Up @@ -247,7 +247,7 @@ We're happy to announce we've recently created an [OpenCollective](https://openc
## Contributing

We're open to all community contributions! If you'd like to contribute in any way, please first read
our [Contributing Guide](https://github.com/nextauthjs/next-auth/blob/main/CONTRIBUTING.md).
our [Contributing Guide](https://github.com/nextauthjs/.github/blob/main/CONTRIBUTING.md).

## License

Expand Down
103 changes: 77 additions & 26 deletions pnpm-lock.yaml

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

0 comments on commit add9e1d

Please sign in to comment.