From 6ede0196199eb265b6e6c0216459fcf07cd62c73 Mon Sep 17 00:00:00 2001 From: DJ Date: Thu, 30 Jul 2020 13:25:27 -0400 Subject: [PATCH] oof --- pages/_app.tsx | 26 ++++++++++++++++++++++++-- pages/test.tsx | 1 + 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/pages/_app.tsx b/pages/_app.tsx index c4696373f..56a7dd256 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -72,7 +72,8 @@ const MainLayout = ({ Component, pageProps }) => { {loadFonts && } - { - + ) } +const MaybeGithubProvider = ({ + useGithub, + enterEditMode, + exitEditMode, + error, + children, +}: any) => { + if (useGithub) { + return ( + + {children} + + ) + } + return children +} + function useShouldLoadFont(cms: TinaCMS) { const [enabled, setEnabled] = React.useState(cms.enabled) diff --git a/pages/test.tsx b/pages/test.tsx index c220557a2..faa65a995 100644 --- a/pages/test.tsx +++ b/pages/test.tsx @@ -23,6 +23,7 @@ export default function TestPage({ guidesIndex, packagesIndex }) { export const getStaticProps = async ({ preview }) => { return { props: { + withoutGithub: true, preview: !!preview, guidesIndex: await readMarkdownFile( path.resolve(process.cwd(), './content/guides/index.md')