OfficeDev / office-scripts-docs-reference

Office Scripts API Reference Documentation
https://learn.microsoft.com/javascript/api/office-scripts/overview
Creative Commons Attribution 4.0 International
49 stars 22 forks source link

Lack of TypeScript null safety #318

Closed lionel-rowe closed 7 months ago

lionel-rowe commented 9 months ago

Article URL

https://github.com/OfficeDev/office-scripts-docs-reference/blob/main/generate-docs/script-inputs/excel.d.ts

Issue

Office Scripts TypeScript types provide no null safety — mostly not clear where nulls are/aren't allowed or occur:

AlexJerabek commented 9 months ago

Hi @lionel-rowe,

Thanks for reporting this. This appears to be a widespread issue here and with the Office JS APIs that sit underneath the Office Scripts API. @gergzk and I will start investigating a fix for both the type definitions and the documentation, though it will likely take some time.

AlexJerabek commented 7 months ago

While we acknowledge this issue, there is no timeline for a complete fix. We will be updating individual APIs to indicate null and undefined behavior as we are able. I'm closing this issue to reflect this level of investment.