File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 22
33import WeatherWidget from "./weather-widget" ;
44import TaskList from "./task-list" ;
5- import Header from "./header" ; // Import the Header component
6- import Footer from "./footer" ; // Import the Footer component
5+ import Header from "./header" ;
6+ import Footer from "./footer" ;
77import { useState } from "react" ;
88
9- const showWeatherWidget = process . env . NEXT_PUBLIC_SHOW_WEATHER_WIDGET ;
10-
119export default function RootLayout ( {
1210 children,
1311} : {
1412 children : React . ReactNode ;
1513} ) {
1614 const [ darkMode , setDarkMode ] = useState ( false ) ;
1715
16+ // Access the Vercel flag
17+ const showWeatherWidget =
18+ process . env . NEXT_PUBLIC_SHOW_WEATHER_WIDGET === "true" ;
19+
1820 const toggleDarkMode = ( ) => {
1921 setDarkMode ( ! darkMode ) ;
2022 } ;
You can’t perform that action at this time.
0 commit comments