* `outputDirectory` is usually the same project setting the static builder uses * (Vite/Webpack/etc. client output). We only reuse it for the Node lambda when we * find a known server entry file under that folder; otherwise we bundle from * source with rolldown. Errors here are swallowed so stati
( dir: string )
| 15 | * not fail the build. |
| 16 | */ |
| 17 | async function findEntrypointInOutputDir( |
| 18 | dir: string |
| 19 | ): Promise<string | undefined> { |
| 20 | try { |
| 21 | return await findEntrypoint(dir); |
| 22 | } catch { |
| 23 | return undefined; |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | export const maybeDoBuildCommand = async ( |
| 28 | args: BuildOptions, |
no test coverage detected