Skip to content

Commit

Permalink
Add specific tsconfig for jest to fix TypeScript support issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
Aleksbgbg committed Jul 15, 2023
1 parent a7e5c64 commit a924ada
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
7 changes: 6 additions & 1 deletion frontend/jest.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@ module.exports = {
"@/(.*)": "<rootDir>/src/$1",
},
transform: {
"^.+\\.ts$": "ts-jest",
"^.+\\.ts$": [
"ts-jest",
{
tsconfig: "./jest.tsconfig.json",
},
],
"^.+\\.vue$": "@vue/vue3-jest",
},
};
7 changes: 7 additions & 0 deletions frontend/jest.tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"types": ["@types/jest"],
"verbatimModuleSyntax": false
}
}

0 comments on commit a924ada

Please sign in to comment.