I experienced the same problem on a react-native project. This fix worked for me:
You have to add “moduleResolution”: “node” to the compiler options in order to include type definitions linked in package.json files.
Documentation here https://www.typescriptlang.org/docs/handbook/module-resolution.html