From 15266f78096186015370f8fd76138627398cc0fe Mon Sep 17 00:00:00 2001 From: Neetish Singh Date: Tue, 16 Apr 2024 19:07:55 +0530 Subject: [PATCH] Bug Fix : Lazy Loader(Async) Render issue #163 I have resolved an issue that was related to the website not rendering properly for async due to import missing in LazyLoader cookiecutter_template --- {{cookiecutter.project_shortname}}/src/lib/LazyLoader.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/{{cookiecutter.project_shortname}}/src/lib/LazyLoader.js b/{{cookiecutter.project_shortname}}/src/lib/LazyLoader.js index 49dee21..f367b20 100644 --- a/{{cookiecutter.project_shortname}}/src/lib/LazyLoader.js +++ b/{{cookiecutter.project_shortname}}/src/lib/LazyLoader.js @@ -1 +1,3 @@ -export const {{cookiecutter.component_name}} = React.lazy(() => import(/* webpackChunkName: "{{cookiecutter.component_name}}" */ './fragments/{{cookiecutter.component_name}}.react')); \ No newline at end of file +import React from 'react'; + +export const {{cookiecutter.component_name}} = React.lazy(() => import(/* webpackChunkName: "{{cookiecutter.component_name}}" */ './fragments/{{cookiecutter.component_name}}.react'));