Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Socket
Sign inDemoInstall

@inquirer/type

Package Overview
Dependencies
Maintainers
0
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@inquirer/type - npm Package Compare versions

Comparing version 1.5.4 to 1.5.5

22

dist/cjs/inquirer.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.CancelablePromise = void 0;
class CancelablePromise extends Promise {
constructor() {
super(...arguments);
Object.defineProperty(this, "cancel", {
enumerable: true,
configurable: true,
writable: true,
value: () => { }
});
}
static withResolver() {
let resolve;
let reject;
const promise = new CancelablePromise((res, rej) => {
resolve = res;
reject = rej;
});
return { promise, resolve: resolve, reject: reject };
}
}
exports.CancelablePromise = CancelablePromise;

13

dist/cjs/types/inquirer.d.ts
import * as readline from 'node:readline';
import MuteStream from 'mute-stream';
export declare class CancelablePromise<T> extends Promise<T> {
cancel: () => void;
static withResolver<T>(): {
promise: CancelablePromise<T>;
resolve: (value: T) => void;
reject: (error: unknown) => void;
};
}
export type InquirerReadline = readline.ReadLine & {

@@ -14,5 +22,2 @@ output: MuteStream;

};
export type Prompt<Value, Config> = (config: Config, context?: Context) => Promise<Value> & {
/** @deprecated pass an AbortSignal in the context options instead. See {@link https://github.com/SBoudrias/Inquirer.js#canceling-prompt} */
cancel: () => void;
};
export type Prompt<Value, Config> = (config: Config, context?: Context) => CancelablePromise<Value>;
{
"name": "@inquirer/type",
"version": "1.5.4",
"version": "1.5.5",
"description": "Inquirer core TS types",

@@ -81,4 +81,3 @@ "main": "./dist/cjs/index.js",

},
"sideEffects": false,
"gitHead": "5fe03a4686d349d0d6cf281f86f12a4f7c992ad4"
"sideEffects": false
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc