Skip to content

Commit

Permalink
chore: setup typescript check
Browse files Browse the repository at this point in the history
lukeed committed May 2, 2022
1 parent 19beff1 commit ead0b88
Showing 3 changed files with 37 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -2,5 +2,7 @@
*.lock
*.log

/tsconfig.json

build/
dist/
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -2,9 +2,12 @@
"private": true,
"scripts": {
"format": "prettier . --write",
"pretest": "prettier . --check"
"pretest": "prettier . --check",
"test": "tsc --noEmit --skipLibCheck"
},
"devDependencies": {
"prettier": "2.6.2"
"@cloudflare/workers-types": "3.8.0",
"prettier": "2.6.2",
"typescript": "4.6.4"
}
}
30 changes: 30 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"compilerOptions": {
"strict": true,
"allowJs": true,
"lib": ["es2020"],
"target": "es2020",
"removeComments": true,
"isolatedModules": true,
"moduleResolution": "node",
"forceConsistentCasingInFileNames": true,
"types": ["@cloudflare/workers-types"],
"strictFunctionTypes": true,
"resolveJsonModule": true,
"strictNullChecks": true,
"noImplicitThis": true,
"noImplicitAny": true,
"alwaysStrict": true,
"module": "esnext",
"checkJs": true,
"noEmit": true
},
"include": [
"worker/**/*",
"worker-*/**/*"
],
"exclude": [
"worker-speedtest/src/test.js",
"worker-typescript/test"
]
}

0 comments on commit ead0b88

Please sign in to comment.