@@ -16,11 +16,11 @@ export async function render (url, ctx = {}, {
1616 staticMarkup = false
1717} = { } ) {
1818 const path = getPath ( url )
19- const mod = await requireModule ( resolve ( dir , '.next' , 'pages' , path ) )
19+ const mod = await requireModule ( resolve ( dir , '.next' , 'dist' , ' pages', path ) )
2020 const Component = mod . default || mod
2121
2222 const props = await ( Component . getInitialProps ? Component . getInitialProps ( ctx ) : { } )
23- const component = await read ( resolve ( dir , '.next' , '_bundles ' , 'pages' , path ) )
23+ const component = await read ( resolve ( dir , '.next' , 'bundles ' , 'pages' , path ) )
2424
2525 const { html, css } = StyleSheetServer . renderStatic ( ( ) => {
2626 const app = createElement ( App , {
@@ -53,7 +53,7 @@ export async function render (url, ctx = {}, {
5353
5454export async function renderJSON ( url , { dir = process . cwd ( ) } = { } ) {
5555 const path = getPath ( url )
56- const component = await read ( resolve ( dir , '.next' , '_bundles ' , 'pages' , path ) )
56+ const component = await read ( resolve ( dir , '.next' , 'bundles ' , 'pages' , path ) )
5757 return { component }
5858}
5959
0 commit comments