Skip to content

Commit

Permalink
Make docs render
Browse files Browse the repository at this point in the history
  • Loading branch information
lachlancollins committed Jan 28, 2024
1 parent f77b535 commit 3a42eef
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
12 changes: 12 additions & 0 deletions app/projects/config.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
import reactLogo from '~/images/react-logo.svg'
import solidLogo from '~/images/solid-logo.svg'
import vueLogo from '~/images/vue-logo.svg'

export const repo = 'tanstack/config'

export const latestBranch = 'main'
Expand All @@ -8,6 +12,14 @@ export const colorFrom = 'from-gray-500'
export const colorTo = 'to-gray-700'
export const textColor = 'text-gray-700'

export const frameworks = {
react: { label: 'React', logo: reactLogo, value: 'react' },
solid: { label: 'Solid', logo: solidLogo, value: 'solid' },
vue: { label: 'Vue', logo: vueLogo, value: 'vue' },
} as const

export type Framework = keyof typeof frameworks

export function getBranch(argVersion?: string) {
const version = argVersion || latestVersion

Expand Down
2 changes: 2 additions & 0 deletions app/routes/config.$version.docs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
repo,
textColor,
availableVersions,
frameworks,
} from '~/projects/config'
import { getTanstackDocsConfig } from '~/utils/config'

Expand All @@ -36,6 +37,7 @@ export default function Component() {
colorTo={colorTo}
textColor={textColor}
config={config}
frameworks={frameworks}
availableVersions={availableVersions}
repo={repo}
>
Expand Down

0 comments on commit 3a42eef

Please sign in to comment.