Skip to content

Commit

Permalink
docs: Update Getting Started Example (#5295)
Browse files Browse the repository at this point in the history
  • Loading branch information
camunoz2 committed Sep 7, 2022
1 parent f1d3bc2 commit 600aaaa
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions docs/docs/getting-started/example.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ To add NextAuth.js to a project create a file called `[...nextauth].js` in `page
import NextAuth from "next-auth"
import GithubProvider from "next-auth/providers/github"

export default NextAuth({
export const authOptions = {
// Configure one or more authentication providers
providers: [
GithubProvider({
Expand All @@ -39,7 +39,9 @@ export default NextAuth({
}),
// ...add more providers here
],
})
}

export default NextAuth(authOptions)
```

All requests to `/api/auth/*` (`signIn`, `callback`, `signOut`, etc.) will automatically be handled by NextAuth.js.
Expand Down

1 comment on commit 600aaaa

@vercel
Copy link

@vercel vercel bot commented on 600aaaa Sep 7, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.