From 709067eeaa3ae45a3548c8b8154a04257122083b Mon Sep 17 00:00:00 2001 From: desmukh Date: Sun, 8 Jan 2023 22:32:47 +0500 Subject: [PATCH] home: hide header --- src/components/layout.js | 38 ++++++++++++++++++++------------------ src/pages/index.js | 2 +- 2 files changed, 21 insertions(+), 19 deletions(-) diff --git a/src/components/layout.js b/src/components/layout.js index 557a71c..0939fc5 100644 --- a/src/components/layout.js +++ b/src/components/layout.js @@ -6,7 +6,7 @@ import theme from "./theme" import Footer from "./footer" import flower from "../images/flower.png" -const Layout = ({ location, title, children }) => { +const Layout = ({ location, title, children, noHeader }) => { // const rootPath = `${__PATH_PREFIX__}/` // const isRootPath = location.pathname === rootPath // let header @@ -29,23 +29,25 @@ const Layout = ({ location, title, children }) => { <> - - - - {title} - - - + {!noHeader && ( + + + + {title} + + + + )} diff --git a/src/pages/index.js b/src/pages/index.js index 76d7efb..f8c7631 100644 --- a/src/pages/index.js +++ b/src/pages/index.js @@ -41,7 +41,7 @@ const BlogIndex = ({ data, location }) => { } return ( - +