import React, { useState } from 'react'; import LandingPage from './components/LandingPage'; import Dashboard from './components/Dashboard'; export default function App() { const [view, setView] = useState('landing'); return ( <> {view === 'landing' ? ( setView('dashboard')} /> ) : ( setView('landing')} /> )} ); }