This template provides a framework for creating custom functions in Google Sheets. It shows the structure needed to define a custom function and its autocomplete documentation, and provides a few examples.
The examples provided here demonstrate:
- How to create custom functions that accept arguments of different types
- How to document a custom function to generate correct autocomplete information in Sheets
Note that this template must be added to a container-bound script attached to a Google Sheet in order to function.
For more information, see Custom Functions in Google Sheets.
In addition, developers of Sheets custom functions should be aware of the known issues specific to Google Sheets.