Skip to content

Commit ad8ff3c

Browse files
authored
Merge pull request #16 from pmcelhaney/convert-to-typescript
convert to typescript
2 parents 832143d + 7b78101 commit ad8ff3c

14 files changed

+13828
-3490
lines changed

.changeset/forty-windows-listen.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"using-temporary-files": minor
3+
---
4+
5+
converted to TypeScript

.editorconfig

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
root = true
33

44
[*]
5-
indent_style = tab
5+
indent_style = space
66
end_of_line = lf
77
charset = utf-8
88
trim_trailing_whitespace = true

.eslintrc.json

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
11
{
2-
"extends": "eslint:recommended",
2+
"extends": ["hardcore", "hardcore/ts", "hardcore/node"],
33
"env": {
44
"node": true,
55
"es6": true,
66
"jest": true
77
},
88
"parserOptions": {
99
"ecmaVersion": 2022,
10-
"sourceType": "module"
10+
"sourceType": "module",
11+
"project": "tsconfig.eslint.json"
12+
},
13+
"rules": {
14+
"import/extensions": "off"
1115
}
1216
}

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: CI Checks
22
on:
33
pull_request:
44
branches:
5-
- "main"
5+
- main
66
jobs:
77
build:
88
name: ci

.rtx.toml

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[tools]
2+
node = "20"

jest.config.js

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
// eslint-disable-next-line import/no-anonymous-default-export
2+
export default {
3+
collectCoverage: true,
4+
5+
collectCoverageFrom: [
6+
"src/**/*.{js,jsx,ts,tsx}",
7+
"!**/node_modules/**",
8+
"!**/*.d.ts",
9+
],
10+
11+
coverageProvider: "v8",
12+
13+
coverageThreshold: {
14+
global: {
15+
branches: 85,
16+
functions: 94,
17+
lines: 94,
18+
statements: 94,
19+
},
20+
},
21+
22+
extensionsToTreatAsEsm: [".ts", ".mts"],
23+
24+
moduleNameMapper: {
25+
"^(\\.{1,2}/.*)\\.js$": "$1",
26+
},
27+
28+
testEnvironment: "node",
29+
30+
testTimeout: 10_000,
31+
32+
transform: {
33+
"^.+\\.(t|j|mj)s?$": "@swc/jest",
34+
},
35+
};

0 commit comments

Comments
 (0)