diff --git a/packages/remix-dev/cli/commands.ts b/packages/remix-dev/cli/commands.ts index a230524a2ee..3d3a7e3173e 100644 --- a/packages/remix-dev/cli/commands.ts +++ b/packages/remix-dev/cli/commands.ts @@ -305,7 +305,9 @@ export async function generateEntry( let defaultEntryClient = path.resolve(defaultsDirectory, "entry.client.tsx"); let defaultEntryServer = path.resolve( defaultsDirectory, - `entry.server.${serverRuntime}.tsx` + ctx?.remixConfig.ssr === false + ? `entry.server.spa.tsx` + : `entry.server.${serverRuntime}.tsx` ); let isServerEntry = entry === "entry.server";