Tutorial doesn't actually work with Node 16
If you do the tutorial steps to start developing with Convex with Node v16.10.0, you'll get an error:
This error can be fixed by upgrading to a newer version of Node. It works fine with v22.12.0.
npm run dev
> convex-tour-chat-0@0.0.0 predev
> convex dev --run init --until-success
/convex-tour-chat/node_modules/convex/dist/cli.bundle.cjs:129136
var retryingFetch = (0, import_fetch_retry.default)(fetch);
^
ReferenceError: fetch is not defined
at Object.<anonymous> (/convex-tour-chat/node_modules/convex/dist/cli.bundle.cjs:129136:53)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:196:29)
at ModuleJob.run (node:internal/modules/esm/module_job:183:25)
at async Loader.import (node:internal/modules/esm/loader:178:24)npm run dev
> convex-tour-chat-0@0.0.0 predev
> convex dev --run init --until-success
/convex-tour-chat/node_modules/convex/dist/cli.bundle.cjs:129136
var retryingFetch = (0, import_fetch_retry.default)(fetch);
^
ReferenceError: fetch is not defined
at Object.<anonymous> (/convex-tour-chat/node_modules/convex/dist/cli.bundle.cjs:129136:53)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:196:29)
at ModuleJob.run (node:internal/modules/esm/module_job:183:25)
at async Loader.import (node:internal/modules/esm/loader:178:24)This error can be fixed by upgrading to a newer version of Node. It works fine with v22.12.0.
