//#region src/get-or-throw.d.ts /** * Get a value from an object or array, and throw an error if the key or index * does not exist or if the resulting value is undefined. * * @param objOrArr The object or array to get the value from. * @param keyOrIndex The key or index to get the value from. * @param errorMessage Optional error message to include in the error thrown. * @returns The value at the given key or index, guaranteed to be defined. * @throws An error if the key or index does not exist, or if the value is * undefined. */ declare function getOrThrow(objOrArr: T, keyOrIndex: K, errorMessage?: string): NonNullable; declare function getOrThrow(objOrArr: T[], keyOrIndex: number, errorMessage?: string): T; //#endregion export { getOrThrow, getOrThrow as got }; //# sourceMappingURL=index.d.mts.map