Installation
npm install --save @types/update-notifier
Summary
This package contains type definitions for update-notifier (https://github.com/yeoman/update-notifier).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/update-notifier/v2.
export = UpdateNotifier;
declare function UpdateNotifier(
settings?: UpdateNotifier.Settings
): UpdateNotifier.UpdateNotifier;
declare namespace UpdateNotifier {
class UpdateNotifier {
constructor(settings?: Settings);
update?: UpdateInfo | undefined;
check(): void;
checkNpm(): void;
notify(customMessage?: NotifyOptions): void;
}
interface Settings {
pkg?: Package | undefined;
callback?(error: Error | null, update?: UpdateInfo): any;
packageName?: string | undefined;
packageVersion?: string | undefined;
updateCheckInterval?: number | undefined;
shouldNotifyInNpmScript?: boolean | undefined;
}
interface BoxenOptions {
padding?: number | undefined;
margin?: number | undefined;
align?: string | undefined;
borderColor?: string | undefined;
borderStyle?: string | undefined;
}
interface NotifyOptions {
message?: string | undefined;
defer?: boolean | undefined;
isGlobal?: boolean | undefined;
boxenOpts?: BoxenOptions | undefined;
}
interface Package {
name: string;
version: string;
}
interface UpdateInfo {
latest: string;
current: string;
type: string;
name: string;
}
}
Additional Details
- Last updated: Fri, 02 Jul 2021 18:04:51 GMT
- Dependencies: none
- Global values: none
Credits
These definitions were written by vvakame, Noah Chen, Jason Dreyzehner, and Michael Grinich.