@@ -3,12 +3,12 @@ import { Pre, Code as NXCode } from "nextra/components"
33import { TSIcon } from "./TSIcon"
44
55interface Props {
6- providerName : string
6+ providerSymbol : string
77 providerId : string
88 highlight : ( code : string ) => string
99}
1010
11- export function SetupCode ( { providerId, providerName , highlight } : Props ) {
11+ export function SetupCode ( { providerId, providerSymbol , highlight } : Props ) {
1212 return (
1313 < Code >
1414 < Code . Next >
@@ -25,10 +25,10 @@ export function SetupCode({ providerId, providerName, highlight }: Props) {
2525 dangerouslySetInnerHTML = { {
2626 __html : highlight ( `
2727import NextAuth from "next-auth"
28- import ${ providerName } from "next-auth/providers/${ providerId } "
28+ import ${ providerSymbol } from "next-auth/providers/${ providerId } "
2929
3030export const { handlers, signIn, signOut, auth } = NextAuth({
31- providers: [${ providerName } ],
31+ providers: [${ providerSymbol } ],
3232})` ) ,
3333 } }
3434 />
@@ -64,10 +64,10 @@ export const { GET, POST } = handlers
6464 dangerouslySetInnerHTML = { {
6565 __html : highlight ( `
6666import { QwikAuth$ } from "@auth/qwik"
67- import ${ providerName } from "@auth/qwik/providers/${ providerId } "
67+ import ${ providerSymbol } from "@auth/qwik/providers/${ providerId } "
6868
6969export const { onRequest, useSession, useSignIn, useSignOut } = QwikAuth$({
70- providers: [${ providerName } ],
70+ providers: [${ providerSymbol } ],
7171}) ` ) ,
7272 } }
7373 />
@@ -86,10 +86,10 @@ export const { onRequest, useSession, useSignIn, useSignOut } = QwikAuth$({
8686 dangerouslySetInnerHTML = { {
8787 __html : highlight ( `
8888import { SvelteKitAuth } from "@auth/sveltekit"
89- import ${ providerName } from "@auth/sveltekit/providers/${ providerId } "
89+ import ${ providerSymbol } from "@auth/sveltekit/providers/${ providerId } "
9090
9191export const { handle, signIn } = SvelteKitAuth({
92- providers: [${ providerName } ],
92+ providers: [${ providerSymbol } ],
9393}) ` ) ,
9494 } }
9595 />
@@ -145,14 +145,14 @@ export const load: LayoutServerLoad = async (event) => {
145145 dangerouslySetInnerHTML = { {
146146 __html : highlight ( `
147147import { ExpressAuth } from "@auth/express"
148- import ${ providerName } from "@auth/express/providers/${ providerId } "
148+ import ${ providerSymbol } from "@auth/express/providers/${ providerId } "
149149import express from "express"
150150
151151const app = express()
152152
153153// If app is served through a proxy, trust the proxy to allow HTTPS protocol to be detected
154154app.set('trust proxy', true)
155- app.use("/auth/*", ExpressAuth({ providers: [ ${ providerName } ] }))
155+ app.use("/auth/*", ExpressAuth({ providers: [ ${ providerSymbol } ] }))
156156` ) ,
157157 } }
158158 />
0 commit comments