mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
Fix dart ref doc
This commit is contained in:
1 parent
547acaf56d
commit
4670cd5ce5
4 files changed
+12
-8
No files matched your search
@@ -6,9 +6,9 @@ import isbot from 'isbot'
|
||||
export function middleware(request: NextRequest) {
|
||||
if (!isbot(request.headers.get('user-agent'))) return
|
||||
|
||||
const clientLibs = ['javascript', 'dart']
|
||||
const specs = ['javascript', 'dart']
|
||||
|
||||
for (const lib of clientLibs) {
|
||||
for (const lib of specs) {
|
||||
if (request.url.includes(`reference/${lib}`)) {
|
||||
const requestSlug = request.url.split('/').pop()
|
||||
|
||||
|
||||
@@ -67,7 +67,6 @@ export default function DartReference(props) {
|
||||
const shortText = hasTsRef ? tsDefinition.signatures[0].comment.shortText : ''
|
||||
|
||||
return (
|
||||
<>
|
||||
<RefSubLayout.Section
|
||||
key={item.id}
|
||||
title={
|
||||
@@ -154,11 +153,11 @@ export default function DartReference(props) {
|
||||
{item.examples &&
|
||||
item.examples.map((example, exampleIndex) => {
|
||||
const exampleString = `
|
||||
import { createClient } from '@supabase/supabase-js'
|
||||
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')
|
||||
`
|
||||
// Create a single supabase client for interacting with your database
|
||||
const supabase = createClient('https://xyzcompany.supabase.co', 'public-anon-key')
|
||||
`
|
||||
const currentExampleId = example.id
|
||||
const staticExample = item.examples[exampleIndex]
|
||||
|
||||
|
||||
@@ -349,6 +349,11 @@ functions:
|
||||
slug: auth-admin-invoke
|
||||
product: 'functions'
|
||||
|
||||
- id: stream
|
||||
title: stream()
|
||||
slug: stream
|
||||
product: 'realtime'
|
||||
|
||||
- id: subscribe
|
||||
title: on().subscribe()
|
||||
slug: subscribe
|
||||
|
||||
@@ -758,7 +758,7 @@ functions:
|
||||
}).subscribe();
|
||||
```
|
||||
|
||||
- id: remove-channnel
|
||||
- id: remove-channel
|
||||
description: |
|
||||
Unsubscribes and removes Realtime channel from Realtime client.
|
||||
title: 'removeChannel()'
|
||||
|
||||
Reference in new issue
Block a user