visilog
Version:
Stream browser console logs to files for LLM debugging. Zero-config setup with simple imports. No MCP required - just tell your LLM to read the log files.
25 lines • 880 B
TypeScript
/**
* Simple middleware for Node.js servers to auto-inject VisiLog
*
* Usage:
* import { createDevMiddleware } from 'visilog/middleware';
*
* app.use(createDevMiddleware({
* port: 3001,
* injectScript: true
* }));
*/
import { Request, Response, NextFunction } from 'express';
interface MiddlewareConfig {
port?: number;
host?: string;
injectScript?: boolean;
logsDir?: string;
enabled?: boolean;
}
export declare function createDevMiddleware(config?: MiddlewareConfig): (req: Request, res: Response, next: NextFunction) => void;
export declare const express: typeof createDevMiddleware;
export declare const koa: (config?: MiddlewareConfig) => (ctx: any, next: any) => Promise<unknown>;
export declare const fastify: (config?: MiddlewareConfig) => (request: any, reply: any, done: any) => void;
export {};
//# sourceMappingURL=middleware.d.ts.map