SENZENN
SENZENN6mo ago

import { anyApi } from "convex/server";^^^^^^SyntaxError: Cannot use import statement outside a m

No description
3 Replies
Matt Luo
Matt Luo6mo ago
I assume you’re trying to follow the tutorial in the convex documentation, since your file name is task You could try adding claude3.5 what the issue is here and provide the tutorial
v
v6mo ago
Do you have a repo Did you try to add "type": "module" to pkgjson
sshader
sshader6mo ago
Check out https://docs.convex.dev/client/javascript/node#javascript-with-commonjs-require-syntax -- Looks like you're using this from a node script?
Node.js | Convex Developer Hub
Convex supports point-in-time queries (see

Did you find this page helpful?