function trackQuery
trackQuery<T>(
sql: string,
fn: () => Promise<T>,
): Promise<T>

Run an async DB operation and log it when tracking is active

Type Parameters

Parameters

sql: string
fn: () => Promise<T>

Return Type

Promise<T>

Usage

import { trackQuery } from "doc.ts";