Finishing up the TypeScript and Mocha porting

I just opened this PR for typing, documenting, and refactoring the Sync class (and a bit of CachingLayer):

It took me a few days to get through this, but it’s looking so much better now! :partying_face:

Most of the types that were still missing are part of this pull request, and the Sync tests have been ported entirely.

I know it’s a lot to ask from a reviewer, but any and all help with getting this merged would be very much appreciated! :pray:

This widget PR uses the new “sync-started” event:

And this one makes it feel snappier simply by removing words from the UI: