import { RequestHandler } from "express"; import type jQuery from "jquery"; import { DOMWindow } from "jsdom"; export type JQuery = typeof jQuery; export interface JqHtmlOptionsContainer { jqHtmlOptions: T; } /** * This is the type of the `options` that are passed to the Express `render()` function. * In particularly, the "engine" will call the `onRender()` function where you can use * jQuery to manipulate the page. */ export type JqHtmlRenderOptions = T & { /** The render function for jquery manipulations */ onRender?( /** The jQuery object */ $: typeof jQuery, /** The window on which to operate */ window: DOMWindow & Omit, 'onRender'>): Promise; }; /** * This middleware ensures that jqHtml can process your request correctly. */ export declare const jqHtmlMiddleware: RequestHandler; /** * */ export declare const __express: (path: string, options: JqHtmlRenderOptions, callback: (e: any, rendered?: string) => void) => void;