Checks crosspost PostOptions before a post is sent. Returns when options are omitted and throws TypeError if images is not an array. Reuse at any publish entry point.
// Source: https://github.com/humanwhocodes/crosspost | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
// Provided via justclaw.it.com; keep this notice with the code.
/**
* @fileoverview Utilities for working with options objects.
* @author Nicholas C. Zakas
*/
//-----------------------------------------------------------------------------
// Type Definitions
//-----------------------------------------------------------------------------
/** @typedef {import("../types.js").PostOptions} PostOptions */
//-----------------------------------------------------------------------------
// Exports
//-----------------------------------------------------------------------------
/**
* Validates post options to ensure they meet requirements
* @par
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key