Skip to content

Commit

Permalink
(chore) Tweak tsconfig lib targets
Browse files Browse the repository at this point in the history
This PR tweaks the base TypeScript config to allow for better module resolution and better support for modern JavaScript features. Specifically, it removes extraneous lib targets. `dom`, `dom.iterable`, and `esnext` are sufficient. `es2018`, `es2020`, `es2021`, and `es2022` are cumulative - each one includes all the previous ones. `esnext` includes all current and proposed ECMAScript features.
  • Loading branch information
denniskigen committed Nov 22, 2024
1 parent 83a1141 commit 52da375
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,20 @@
"jsx": "react",
"lib": [
"dom",
"es5",
"scripthost",
"es2015",
"es2015.promise",
"es2016.array.include",
"es2018",
"es2020",
"es2021",
"es2022"
"dom.iterable",
"esnext"
],
"module": "esnext",
"moduleResolution": "node",
"noEmit": true,
"paths": {
"@openmrs/*": ["./node_modules/@openmrs/*"],
"__mocks__": ["./__mocks__"],
"tools": ["./tools"],
"tools": ["./tools"]
},
"resolveJsonModule": true,
"skipLibCheck": true,
"strictNullChecks": true,
"target": "esnext",
"target": "esnext"
}
}

0 comments on commit 52da375

Please sign in to comment.