Next.js Discord

Discord Forum

some Typescript error

Unanswered
Flemish Giant posted this in #help-forum
Open in Discord
Flemish GiantOP
mr.blackghost@Akashs-Mac-mini http-server % pnpm run start

http-server@1.0.0 start /Users/mr.blackghost/Documents/Projects/sketchTogether/apps/http-server
node ./dist/index.js

node:internal/modules/esm/get_format:219
throw new ERR_UNKNOWN_FILE_EXTENSION(ext, filepath);
^

TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" for /Users/mr.blackghost/Documents/Projects/sketchTogether/packages/db/src/client.ts
at Object.getFileProtocolModuleFormat [as file:] (node:internal/modules/esm/get_format:219:9)
at defaultGetFormat (node:internal/modules/esm/get_format:245:36)
at defaultLoad (node:internal/modules/esm/load:120:22)
at async ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:483:32) {
code: 'ERR_UNKNOWN_FILE_EXTENSION'
}

Node.js v22.13.0 i got this error it try to solve but not able to can you help what wrong i doing

1 Reply

Spectacled bear
Is typescript configured for the project or system?