INNER CODE UNIT · JavaScript
HomePage
misa-j/social-network · client/src/App.js:14
const HomePage = lazy(() => import("./HomePage/HomePage"));
const LoginPage = lazy(() => import("./LoginPage/LoginPage"));
const RegisterPage = lazy(() => import("./RegisterPage/RegisterPage"));
const ProfilePage = lazy(() => import("./ProfilePage/ProfilePage"));
const UserProfile = lazy(() => import("./UserProfile/UserProfile"));
const PostUploadPage = lazy(() => import("./PostUploadPage/PostUploadPage"));
const PostPage = lazy(() => import("./PostPage/PostPage"));
const HashtagPage = lazy(() => import("./HashtagPage/HashtagPage"));
const LocationPage = lazy(() => import("./LocationPage/LocationPage"));
const MessengerPage = lazy(() => import("./MessengerPage/MessengerPage"));
const Navbar = lazy(() => import("./components/Navbar"));
class App extends React.Component {
componentDidMount() {
const { dispatch } = this.props;
window.addEventListener("scroll", this.handleNotificationPopupClose);
history.listen((location, action) => {
// clear alert on location change