Shouldn't the properties in interface WorksheetGridProperties be marked optional? Right now TypeScript throws an error if all properties are not provided by default.
I'm not so sure about that: when updating the grid properties, the package doesn't internally assign your new properties to the existing ones, it just sends your object to the API.
The package docs refer to the Sheets API, so that doesn't help.
Try to use to edit some properties in sequence and see if the properties you're not editing get reset or just stay the same: with that we'll know if they're optional or not. You can suppress the errors with //@ts-expect-error, only as a temporary measure.
@the-vampiire Do you have any info on this?
@EndBug youre right. it just proxies it over to google. reading the google docs:
When writing it is an error to set any grid properties on non-grid sheets.
If this sheet is a DATA_SOURCE sheet, this field is output only but contains the properties that reflect how a data source sheet is rendered in the UI, e.g. rowCount
for this reason i think they should be optional. since you may choose to update one or multiple properties in a single call. unless i am misunderstanding.
I've published a PR that uses the Partial type to make everything optional: we just need to wait for the tests and the approval process.