-
-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
My linter raises this error
suggestion:
instead of :
export = PGPubsub;
/** @typedef {(payload: any) => void} PGPubsubCallback */
declare class PGPubsub extends NodeJS.EventEmitter {
use
/** @typedef {(payload: any) => void} PGPubsubCallback */
export class PGPubsub extends NodeJS.EventEmitter {
same for
declare namespace PGPubsub {
export { PGPubsubCallback };
}
type PGPubsubCallback = (payload: any) => void;
use
export type PGPubsubCallback = (payload: any) => void;
no need to add complex namespace and avoid using a global declare at all cost.
Usage will be
import {PGPubsub} from 'pg-pubsub'; Which is ES6 compliant
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels