Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

Policy

import type { Policy } from "https://gitlab.com/soapbox-pub/strfry-policies/-/raw/develop/mod.ts";

A policy function in this library. It accepts an input message, opts, and returns an output message.

type Policy<Opts = unknown> = (msg: InputMessage, opts?: Opts) => Promise<OutputMessage> | OutputMessage;

§Type Parameters

§
Opts = unknown
[src]

§Type

§
(msg: InputMessage, opts?: Opts) => Promise<OutputMessage> | OutputMessage
[src]