The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Use single quotes to comply with custom prettier config
Fabián Uribe7a8b65fc0724
diff --git a/apps/docs/pages/guides/auth/social-login/auth-google.mdx b/apps/docs/pages/guides/auth/social-login/auth-google.mdxindex ee774b24fbc..e1c4a8f9516 100644--- a/apps/docs/pages/guides/auth/social-login/auth-google.mdx+++ b/apps/docs/pages/guides/auth/social-login/auth-google.mdx@@ -301,21 +301,22 @@ The following code snippet provides an example of how to create both versions in```js// Adapted from https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/digest#converting_a_digest_to_a_hex_string-import crypto from "crypto";+import crypto from 'crypto'// ...-const nonce = crypto.randomBytes(16).toString("base64"); // Generate a random nonce-const encoder = new TextEncoder();-const encodedNonce = encoder.encode(nonce); // Encode the nonce-const hash = await crypto.subtle.digest("SHA-256", encodedNonce); // Hash it with SHA-256-const bytes = new Uint8Array(hash);+const nonce = crypto.randomBytes(16).toString('base64') // Generate a random nonce+const encoder = new TextEncoder()+const encodedNonce = encoder.encode(nonce) // Encode the nonce+const hash = await crypto.subtle.digest('SHA-256', encodedNonce) // Hash it with SHA-256+const bytes = new Uint8Array(hash)const hashedNonce = Array.from(bytes)- .map((b) => b.toString(16).padStart(2, "0")) // Convert the hash to a hexadecimal string- .join("");+ .map((b) => b.toString(16).padStart(2, '0')) // Convert the hash to a hexadecimal string+ .join('')// Use 'hashedNonce' when making the authentication request to Google// Use 'nonce' when invoking the supabase.auth.signInWithIdToken() method+```### Configuration [#configuration-personalized-sign-in-button]