balena-io / open-balena-api

The core API of openBalena
https://balena.io/open
GNU Affero General Public License v3.0
58 stars 29 forks source link

Update @balena/pinejs and make use of model based typings #1670

Closed Page- closed 1 month ago

Page- commented 2 months ago

Change-type: patch

Page- commented 1 month ago

I can put the second commit as a separate PR if people want but I thought it made sense to live here to show the additional things that model based typings unlock

otaviojacobi commented 1 month ago

This all looks very nice, I would just like to have the typings removed on the places we added the "as const" cast (or the const cast removed) - The reason being, the ones we haven't touched we know they just need improving in following PRs, but seeing one with const cast (meaning - we know this is using the new typings) and with the as casting at the end makes me think it is there for a reason rather than just we forgot to remove