text: import "bootstrap/dist/css/bootstrap.min.css";
  import "./App.css";
  import AppNavbar from "./components/AppNavbar";
  import ShoppingList from "./components/ShoppingList";
  import ItemModal from "./components/itemModal";
  import { Container } from "reactstrap";
  
  import { Provider } from "react-redux";
  import store from "./store";
  import { loadUser } from "./actions/authActions";
  import React, { useState, useEffect } from "react";
  
  function App() {
    // Similar to componentDidMount and componentDidUpdate:
    useEffect(() => {
      store.dispatch(loadUser());
    });
  
    return (
      <Provider store={store}>
        <div className="App">
          <AppNavbar />
          <Container>
            <ItemModal />
            <ShoppingList />
          </Container>
        </div>
      </Provider>
    );
  }
  
  export default App;
  