Skip to content

Commit 93bd39b

Browse files
authored
Convert nodes.js to TypeScript (#1748)
## Summary: After updating nodes.js to ues ES6 classes in #1747, the move to TypeScript became much more feasible. While this PR mostly just adds types in a bunch of places, there are some changes to the code itself in order to minimize the number of casts and @ts-expect-errors that were require. I've tried to keep these kinds of changes to a minimum. I ended up converting a bunch of function expressions to arrow functions. Hopefully that doesn't add too much additional overhead when reviewing. There's still more cleanup that could be done (adding more missing types, converting all `var`s to either `const` or `let`, etc.), but I'm going to leave that for a future PR. Issue: None ## Test plan: - yarn test packages/kas/src Author: kevinb-khan Reviewers: kevinb-khan, handeyeco, jeremywiebe Required Reviewers: Approved By: handeyeco Checks: ✅ Publish npm snapshot (ubuntu-latest, 20.x), ✅ Check builds for changes in size (ubuntu-latest, 20.x), ✅ Lint, Typecheck, Format, and Test (ubuntu-latest, 20.x), ✅ Cypress (ubuntu-latest, 20.x), ✅ Check for .changeset entries for all changed files (ubuntu-latest, 20.x), ✅ Publish Storybook to Chromatic (ubuntu-latest, 20.x), ✅ gerald Pull Request URL: #1748
1 parent 81ee69b commit 93bd39b

File tree

2 files changed

+751
-688
lines changed

2 files changed

+751
-688
lines changed

.changeset/rare-pumas-rule.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@khanacademy/kas": patch
3+
---
4+
5+
Convert nodes.js to use TypeScript

0 commit comments

Comments
 (0)