#node SSR standalone adapter: schedule tasks within node-cron
14 messages · Page 1 of 1 (latest)
node SSR standalone adapter: schedule tasks within node-cron
That's a dev hook, for when the Dev server start
Once the app Is built, hooks don't apply anymore
You should use the middleware mode of the adapter, so you can hook the Cron with express/fastify or any web server you want to use
I see
Am I undeerstanding correctly from the docs that in middleware mode:
- I have to build first
- Hot reloading doesn't work
?
- You always have to build an Astro project
- Hot reloading works only in dev, it doesn't work in production (after the build)
It seems to me that you're using the dev server in production. Don't do that 🙂
No no I meant just locally
Seems like pnpm install && pnpm dev / astro dev works without building, or am I missing something?
Maybe we are misunderstanding each other: is it possible to have the same server entrypoint in both dev and production?