UNPKG

express-user-agent-blocker

Version:

Express middleware for blocking access based on User Agent

10 lines (9 loc) 466 B
import { Response } from 'express'; import { Options } from '../definitions/options'; /** * Responds to a blocked user agent, either with the default message, or an optional custom message * @param {Response} res the response object * @param {Options} [options] will respond with a custom {@link Options#html} or {@link Options#text} message, if set */ declare const respondToBlockedUa: (res: Response, options?: Options) => void; export { respondToBlockedUa };