Despite moduleResolution being set to Node16 the TS1452 error occurs.
package.json includes "type":"module" as well, and has no exports. I have tried all the conceivable permutations I can think of. I admit I'm likely nowhere near as adept as many of you with TypeScript, my actual code is just importing Got and then got.extend
Actual behavior
../../node_modules/cacheable-request/dist/types.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/cacheable-request/dist/types.d.ts(2,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/cacheable-request/dist/types.d.ts(3,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/cacheable-request/dist/types.d.ts(4,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/form-data-encoder/@type/FormDataEncoder.d.ts(19,5): error TS18028: Private identifiers are only available when targeting ECMAScript 2015 and higher.
../../node_modules/got/dist/source/as-promise/types.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/errors.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/index.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/index.d.ts(2,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/index.d.ts(3,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/index.d.ts(4,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/index.d.ts(5,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(2,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(3,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(4,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(5,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(6,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(7,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(8,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(9,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/options.d.ts(13,8): error TS1192: Module '"node:http"' has no default export.
../../node_modules/got/dist/source/core/options.d.ts(14,8): error TS1192: Module '"node:https"' has no default export.
../../node_modules/got/dist/source/core/options.d.ts(21,8): error TS1192: Module '"/home/codyfrisch/src/monday-sdk-nodejs/node_modules/http2-wrapper/index"' has no default export.
../../node_modules/got/dist/source/core/response.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/core/response.d.ts(2,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/types.d.ts(1,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
../../node_modules/got/dist/source/types.d.ts(2,23): error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.
Expected behavior
Successfully build using tsc.
Code to reproduce
Below is the tsconfig.json which is shows moduleResolution is node16.
Well this is entirely on me. my build script was tsc index.mts and it works fine as just "tsc". mea culpa, only been doing this six months, and self taught. bound to be human error.
Describe the bug
Despite moduleResolution being set to Node16 the TS1452 error occurs.
package.json includes "type":"module" as well, and has no exports. I have tried all the conceivable permutations I can think of. I admit I'm likely nowhere near as adept as many of you with TypeScript, my actual code is just importing Got and then got.extend
Actual behavior
Expected behavior
Successfully build using tsc.
Code to reproduce
Below is the tsconfig.json which is shows moduleResolution is node16.
Checklist