💡 TIL — the new `node --run` flag doesn't run life cycle scripts.
Node.js v23 was released last week and ships a new and stable `node --run` flag. The flag allows running `package.json` scripts without npm. It's slightly faster than `npm run` (we're talking a couple of hundred ms) but doesn't run life cycle scripts (e.g. `prestart`).
So `node --run` is not an `npm run` replacement.
Will you use it? I'd rather stick with `npm run` in this case... 🤔
@stefan i find automatically-called lifecycle scripts confusing anyway, so i prefer explicitly calling things. in this case, i'd prepend `node --run prestart &&` to the value of the `start` script.