I have a TypeScript project that I push to Google Apps Scripts via clasp.
I'm using functions like Utilities.formatDate
and const input = SpreadsheetApp.getUi().prompt('Paste the URL here.');
.
I see errors like 'Utilities' is not defined. eslint(no-undef)
and 'SpreadsheetApp' is not defined. eslint(no-undef)
.
I don't want to simply disable the no-undef
rule.
How can I properly import those dependencies?
Docs:
https://developers.google.com/apps-script/reference/spreadsheet/spreadsheet-app#getui