Skip to content

Instantly share code, notes, and snippets.

@EnetoJara
Created May 4, 2020 12:53
Show Gist options
  • Save EnetoJara/41e9d732d3174a8f31b029cddb680628 to your computer and use it in GitHub Desktop.
Save EnetoJara/41e9d732d3174a8f31b029cddb680628 to your computer and use it in GitHub Desktop.
import * as React from "react";
import * as Loadable from "react-loadable";
const Loading = (): React.ReactElement => <span>Loadong</span>;
export const List = Loadable({
loader: () => import(/* webpackChunkName: "lists" */ "./list-constainer"),
loading: Loading,
});
export const User = Loadable({
loader: () => import(/* webpackChunkName: "register" */ "./users-container"),
loading: Loading,
});
export const Lists = Loadable({
loader: () => import(/* webpackChunkName: "LandingPage" */ "./lists-constainer"),
loading: Loading,
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment