Critical fix start script for tanstack start addon #179
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
create-start-app
creates a broken start script based on previous nitro plugin leftouts. This is creating lots of confusion whoever is trying to deploy on prod as server fails to start.This PR adds a simple server based on srvx prod server which Tanstack start already internally uses in order to create a server script that runs for all node/bun/deno.
Please note, npm and bun do not need srvx to be added but pnpm requires explicit install, hence added it to
package.json
file as well which is anyways a good practise.Modified the start script command from
"node .output/server/index.mjs"
tosrvx --prod server.js
.Used srvx cli as it shows a bit more nice output logs than simple
node server.js
skips.