code splitting
Closed this issue · 0 comments
maifeeulasad commented
import React, { Suspense, lazy } from 'react';
const SomeComponent = lazy(() => import('./path/to/some/component'));
<Suspense fallback={<div>Loading...</div>}>
<SomeComponent />
</Suspense>