6

i'm facing with the following error error TS6044: Compiler option 'types' expects an argument. when trying to set "types": [] in tsconfig.json.

We are using grunt-ts

This is recommended by official TS documentation in order to get rid of the following errors: node_modules/@types/angular/index.d.ts(14,9): error TS2403

Here is the link to TS documentation

Specify "types": [] to disable automatic inclusion of @types packages.

But instead of disabling automatic inclusion of @types i see error error TS6044: Compiler option 'types' expects an argument.

Can someone help me?

Community
  • 1
  • 1
VladosJS
  • 1,210
  • 8
  • 20

2 Answers2

1

I would recommend using tsconfig.json passthrough with that parameter and grunt-ts. Several of the new features in the TypeScript 2.x timeframe don't work very well or at all from the command-line. Alternatively, you could try using the additionalFlags feature of grunt-ts and pass "" as the types value. I'm not near a computer to test that, but it could work.

NYCdotNet
  • 4,500
  • 1
  • 25
  • 27
0

Finally i've solved my problem specifying jasmine in types "types" : ["jasmine"]

VladosJS
  • 1,210
  • 8
  • 20