[Beta] Drop next/dynamic usage (#4695)

This commit is contained in:
Sukka
2022-05-26 22:03:19 +08:00
committed by GitHub
parent 53de0f721f
commit e6dfdd34fe

View File

@@ -3,10 +3,9 @@
*/
import * as React from 'react';
import dynamic from 'next/dynamic';
import {createFileMap} from './createFileMap';
const SandpackRoot = dynamic(() => import('./SandpackRoot'), {suspense: true});
const SandpackRoot = React.lazy(() => import('./SandpackRoot'));
const SandpackGlimmer = ({code}: {code: string}) => (
<div className="sandpack-container my-8">