We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 36ad22a commit 5cc805dCopy full SHA for 5cc805d
src/08-advanced-patterns/63-lazy-load-component.problem.tsx
@@ -11,8 +11,10 @@ type Props = {
11
* But it's not typed correctly, and it's not generic enough.
12
* Fix the typing errors, and make it generic enough to support any component.
13
*
14
- * Hint - React.ComponentProps will come in handy - as will a helper called
15
- * React.ComponentType.
+ * Hints:
+ *
16
+ * - You'll need to make this a generic component!
17
+ * - React.ComponentProps will come in handy, as will React.ComponentType
18
*/
19
function LazyLoad({ loader, ...props }: Props) {
20
const LazyComponent = useMemo(() => lazy(loader), [loader]);
0 commit comments