Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

adds a few more options to make the docs clearer (#3742)

Copple9dbd3521ad7b
diff --git a/web/spec/supabase.yml b/web/spec/supabase.yml
index abdce37288b..2e996ce3b98 100644
--- a/web/spec/supabase.yml
+++ b/web/spec/supabase.yml
@@ -150,23 +150,29 @@ pages:
import { createClient } from '@supabase/supabase-js'
// Create a single supabase client for interacting with your database
- const supabase = createClient("https://xyzcompany.supabase.co", "public-anon-key")
+ const supabase = createClient('https://xyzcompany.supabase.co', 'public-anon-key')
```
- name: With additional parameters
js: |
```js
import { createClient } from '@supabase/supabase-js'
- const options = { }
+ const options = {
+ schema: 'public',
+ headers: { 'x-my-custom-header': 'my-app-name' },
+ autoRefreshToken: true,
+ persistSession: true,
+ detectSessionInUrl: true
+ }
const supabase = createClient("https://xyzcompany.supabase.co", "public-anon-key", options)
```
- - name: With additional parameters - access non-public schemas
+ - name: API schemas
js: |
```js
import { createClient } from '@supabase/supabase-js'
- const options = {schema: "other_schema"}
- const supabase = createClient("https://xyzcompany.supabase.co", "public-anon-key", options)
+ const options = { schema: 'other_schema' }
+ const supabase = createClient('https://xyzcompany.supabase.co', 'public-anon-key', options)
```
By default the API server points to the `public` schema. You can enable others database schemas within the Dashboard.