Upgrade TypeScript, unified watcher setup#959
Draft
simolus3 wants to merge 12 commits into
Draft
Conversation
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Blocked on #958.
When working on internal SDK changes in
common, it's convenient to be able to see what needs to be changed in the individual SDK packages consuming that. Right now though, that process requires rebuilding every package in this repository, which is very slow.In the PowerSync service, one can simply run
pnpm watch:tsto run tsc everytime something changes, which is much faster than having to invokerollupon every package. Packages still have their complex build logic, but running TypeScript is the first step of that. In the future, I hope we get to make it the only step for most packages, but we're not really there yet.This also upgrades to TypeScript version 6. I mainly had to change a few
catchblocks which correctly use anunknowntype by default (but we can change that toany). We also a few packages opting in to strict type checks without really having save code - I've added!assertions to keep existing semantics. Finally, resolving types invueandnuxtis beyond broken for reasons I don't understand (it looks like types are resolved against@powersync/common/distwhile symbols are resolved against@powersync/common/lib??). A fewas anyfix this, when we split common into interfaces and implementation we should be able to fix this properly.