-
-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathisTextStyle.ts
More file actions
15 lines (14 loc) · 848 Bytes
/
isTextStyle.ts
File metadata and controls
15 lines (14 loc) · 848 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import { isObject } from "../../lang";
/**
* Checks if the given value is a Google Apps Script <a href="https://developers.google.com/apps-script/reference/spreadsheet/text-style"><code>TextStyle</code></a> object.
*
* @param {unknown} value - The value to check.
* @returns {boolean} `true` if the value is a <a href="https://developers.google.com/apps-script/reference/spreadsheet/text-style"><code>TextStyle</code></a> object, `false` otherwise.
* @see <a href="https://developers.google.com/apps-script/reference/spreadsheet/text-style"><code>TextStyle</code></a>
* @since 1.0.0
* @version 1.0.0
* @environment `Google Apps Script`, `Browser`
*/
export function isTextStyle(value: unknown): value is GoogleAppsScript.Spreadsheet.TextStyle {
return isObject(value) && value?.toString() === "TextStyle";
}