UNPKG

one

Version:

One is a React framework for web, iOS, and Android apps.

11 lines (7 loc) • 337 B
import { assertActionHandler } from './validate' export type AppIntentHandler = (text: string | null) => string | Promise<string> function defineAction(identifier: string, handler: AppIntentHandler): () => void { assertActionHandler(identifier, handler) return () => {} } export const AppIntents = Object.freeze({ defineAction })