We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Take a more TypeScript approach to logging
export enum LogAction { request, parse, validation, execute }
export enum LogStep { start, end }
export interface LogMessage { action: LogAction; step: LogStep; data?: Object; }
export interface LogFunction { (message: LogMessage); }
export interface QueryOptions { ... logFunction?: LogFunction; ... }
Then use it like this: logFunction({action: LogAction.request, step: LogStep.start});
This is more verbose but avoids string matching / parsing and makes it much easier for the consumer.
The text was updated successfully, but these errors were encountered:
chore(deps): update dependency @types/node to v8.10.47 (#79)
6f12243
85eb10a
nnance
No branches or pull requests
Take a more TypeScript approach to logging
export enum LogAction {
request, parse, validation, execute
}
export enum LogStep {
start, end
}
export interface LogMessage {
action: LogAction;
step: LogStep;
data?: Object;
}
export interface LogFunction {
(message: LogMessage);
}
export interface QueryOptions {
...
logFunction?: LogFunction;
...
}
Then use it like this:
logFunction({action: LogAction.request, step: LogStep.start});
This is more verbose but avoids string matching / parsing and makes it much easier for the consumer.
The text was updated successfully, but these errors were encountered: