@ -172,16 +172,20 @@ export async function bundle(
configFile : config.vite?.configFile
configFile : config.vite?.configFile
} )
} )
let clientResult : Rolldown.RolldownOutput | null = null
let { clientResult , serverResult } = await task (
let serverResult ! : Rolldown . RolldownOutput
'building client + server bundles' ,
async ( ) = > {
// prettier-ignore
const clientResult = config . mpa
await task ( 'building client + server bundles' , async ( ) = > {
? null
if ( ! config . mpa ) clientResult =
: ( ( await build (
( await build ( await resolveViteConfig ( false ) ) ) as Rolldown . RolldownOutput
await resolveViteConfig ( false )
serverResult =
) ) as Rolldown . RolldownOutput )
( await build ( await resolveViteConfig ( true ) ) ) as Rolldown . RolldownOutput
const serverResult = ( await build (
} )
await resolveViteConfig ( true )
) ) as Rolldown . RolldownOutput
return { clientResult , serverResult }
}
)
if ( config . mpa ) {
if ( config . mpa ) {
// in MPA mode, we need to copy over the non-js asset files from the
// in MPA mode, we need to copy over the non-js asset files from the