import { EffectType } from '@devvit/protos/json/devvit/ui/effects/v1alpha/effect.js'; import { type WebViewInternalMessage } from '@devvit/protos/json/devvit/ui/effects/web_view/v1alpha/post_message.js'; import type { WebViewInternalEventMessage } from '@devvit/protos/json/devvit/ui/events/v1alpha/web_view.js'; /** `WebViewInternalMessage.type`. */ export declare const webViewInternalMessageType = "devvit-internal"; export type Effect = Omit & { type: EffectType; }; /** * Emits an effect to the parent window returns immediately. * * @param effect - The effect to be emitted to the parent window * @param requestId - Optional request id used to correlate request/response messages * @description * This function handles effects that don't require a response, and can also * set a request id when replying to client-originated requests. */ export declare const emitEffect: (effect: Readonly, requestId?: string) => void; /** * Emits an effect to the parent window and returns a promise that resolves with the response message. * * @param effect - The effect to be emitted to the parent window * @returns A promise that resolves with the response message * * @description * This function handles effects that require a response. */ export declare const emitEffectWithResponse: (effect: Readonly) => Promise; //# sourceMappingURL=emit-effect.d.ts.map