mirror of
https://github.com/vercel/commerce.git
synced 2025-07-22 12:24:18 +00:00
fix: dynamically import Modal component
fixes error "document is not defined" if the user decides to display a modal at the beginning (for ads, promotions, etc...)
This commit is contained in:
@@ -42,6 +42,11 @@ const FeatureBar = dynamic(
|
||||
dynamicProps
|
||||
)
|
||||
|
||||
const Modal = dynamic(
|
||||
() => import('@components/interface/Modal'),
|
||||
{...dynamicProps, ssr: false}
|
||||
)
|
||||
|
||||
interface Props {
|
||||
pageProps: {
|
||||
pages?: Page[]
|
||||
|
Reference in New Issue
Block a user