I have this component:
import React from \'react\';
import VideoTag from \'./VideoTag\';
import JWPlayer from \'./JWPlayer\';
class VideoWrapper extends React.C
For others ending up here trying to use Jest with TypeScript: you need to include ts
in the moduleFileExtensions
, e.g.:
"moduleFileExtensions": [
"js",
"jsx",
"json",
"node",
"ts"
]
You also need a transform for *.ts
files:
transform: {
"^.+\\.vue$": "vue-jest",
"^.+\\.js$": "babel-jest",
"^.+\\.(ts|tsx)$": "ts-jest"
},