clasp

Enabling autocomplete for Google Apps Script in locally-installed IDE

三世轮回 提交于 2019-12-28 05:23:39
问题 I'm trying to build GAS projects locally using clasp https://github.com/google/clasp Any locally-installed IDE is a huge improvement over Google's Script Editor, so the tool looks very promising. Unfortunately, the autocomplete feature for GAS services doesn't seem to be included in the package. The documentation says: The Apps Script CLI uses TypeScript to provide autocompletion and linting when developing. Use an IDE like Visual Studio Code for TypeScript autocompletion. After going through

Abbreviate lengthy TypeScript Types

自闭症网瘾萝莉.ら 提交于 2019-12-24 10:19:01
问题 I'm developing a Google Apps Script (GAS) using Typescript (via the clasp tool). I imported type definitions by running npm i -S @types/google-apps-script . Some types are quite lengthy, for example: let sheet: GoogleAppsScript.Spreadsheet.Sheet Is there a way to define an abbreviation within a file? e.g., declare Sheet = GoogleAppsScript.Spreadsheet.Sheet 回答1: You can define new alias type: type Sheet = GoogleAppsScript.Spreadsheet.Sheet 来源: https://stackoverflow.com/questions/53198823

Use Typescript with Google Apps Script

倾然丶 夕夏残阳落幕 提交于 2019-12-12 13:17:49
问题 I'd like to use Typescript for my Google Apps Script (GAS) projects, but I can't find a way to compile my code into something that GAS accepts. GAS doesn't support export, and Typescript seems to dislike accessing variables via the global scope (it wants imports/require, and thus exports). I'm looking for any of the following solutions which I believe would make things work for me: 1) Babel plugin or the like that can remove all the Import and Export statements along with their attributed

Enabling autocomplete for Google Apps Script in locally-installed IDE

ぃ、小莉子 提交于 2019-11-28 06:02:38
I'm trying to build GAS projects locally using clasp https://github.com/google/clasp Any locally-installed IDE is a huge improvement over Google's Script Editor, so the tool looks very promising. Unfortunately, the autocomplete feature for GAS services doesn't seem to be included in the package. The documentation says: The Apps Script CLI uses TypeScript to provide autocompletion and linting when developing. Use an IDE like Visual Studio Code for TypeScript autocompletion. After going through the steps and installing all required dependencies, I'm still unable to get the autocomplete feature