Week Log 3

Rewrite of Week Log using Next.js, Typescript, PostgreSQL and Prisma

🎨 Types types types

22nd February 2021

  • Started looking for chunks of work I could pick off and commit
  • Refactored obscure functions as generics, using type guards
  • Completed the move to strict mode
  • Tidied up a few loose ends

I had a run-in with strict function types. When we're building our factories using combine(), the types don't add up. After reading the suggested writeup I think I understand the background a little better, but not enough to understand why the factory construction is invalid. I've overridden the type checking for now (using as) which is a poor solution, but it'll do until I can get a better understanding of the problem.