mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
24 lines
869 B
TypeScript
24 lines
869 B
TypeScript
// @ts-expect-error
|
|
import spec from '~/../../spec/cli_v1_commands_new_shape.yaml' assert { type: 'yml' }
|
|
|
|
import { flattenSections } from '~/lib/helpers'
|
|
|
|
import cliCommonSections from '~/../../spec/common-cli-sections.json' assert { type: 'json' }
|
|
import RefSectionHandler from '~/components/reference/RefSectionHandler'
|
|
import handleRefGetStaticPaths from '~/lib/mdx/handleRefStaticPaths'
|
|
import handleRefStaticProps from '~/lib/mdx/handleRefStaticProps'
|
|
|
|
const sections = flattenSections(cliCommonSections)
|
|
|
|
export default function CliRef(props) {
|
|
return <RefSectionHandler sections={sections} spec={spec} pageProps={props} type="cli" />
|
|
}
|
|
|
|
export async function getStaticProps({ params }: { params: { slug: string[] } }) {
|
|
return handleRefStaticProps(sections, params, '/cli', '/cli')
|
|
}
|
|
|
|
export function getStaticPaths() {
|
|
return handleRefGetStaticPaths()
|
|
}
|