mirror of
https://github.com/supabase/supabase.git
synced 2026-05-27 14:58:19 +08:00
29 lines
551 B
TypeScript
29 lines
551 B
TypeScript
import type { Json, Section } from '../../helpers.mdx'
|
|
|
|
export abstract class BaseLoader {
|
|
type: string
|
|
|
|
constructor(
|
|
public source: string,
|
|
public path: string
|
|
) {}
|
|
|
|
abstract load(): Promise<BaseSource[]>
|
|
}
|
|
|
|
export abstract class BaseSource {
|
|
type: string
|
|
checksum?: string
|
|
meta?: Json
|
|
sections?: Section[]
|
|
|
|
constructor(
|
|
public source: string,
|
|
public path: string
|
|
) {}
|
|
|
|
abstract process(): { checksum: string; meta?: Json; ragIgnore?: boolean; sections: Section[] }
|
|
|
|
abstract extractIndexedContent(): string
|
|
}
|