@telegram-apps/sdk
Version:
TypeScript Source Development Kit for Telegram Mini Apps client application.
15 lines (14 loc) • 573 B
TypeScript
/**
* Prompts the user to add the Mini App to the home screen.
* @since Mini Apps v8.0
* @throws {FunctionNotAvailableError} The environment is unknown
* @throws {FunctionNotAvailableError} The SDK is not initialized
* @throws {FunctionNotAvailableError} The function is not supported
* @example Using `isAvailable`
* if (addToHomeScreen.isAvailable()) {
* addToHomeScreen();
* }
* @example Using `ifAvailable`
* addToHomeScreen.ifAvailable()
*/
export declare const addToHomeScreen: import('../../wrappers/wrapSafe.js').SafeWrapped<() => void, true, never>;