mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
### Why? In preparation for moving all turbopack crates Also makes them easier to work with in general. Closes PACK-3164
19 lines
486 B
JavaScript
19 lines
486 B
JavaScript
import dynamic1 from 'next/dynamic';
|
|
import dynamic2 from 'next/dynamic';
|
|
const DynamicComponent1 = dynamic1(()=>import('../components/hello1')
|
|
, {
|
|
loadableGenerated: {
|
|
webpack: ()=>[
|
|
require.resolveWeak("../components/hello1")
|
|
]
|
|
}
|
|
});
|
|
const DynamicComponent2 = dynamic2(()=>import('../components/hello2')
|
|
, {
|
|
loadableGenerated: {
|
|
webpack: ()=>[
|
|
require.resolveWeak("../components/hello2")
|
|
]
|
|
}
|
|
});
|