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

@inquirer/editor

Package Overview
Dependencies
Maintainers
3
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@inquirer/editor - npm Package Compare versions

Comparing version 1.2.9 to 1.2.10

9

./dist/cjs/index.js

@@ -11,8 +11,11 @@ "use strict";

};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const chalk_1 = require("chalk");
const chalk_1 = __importDefault(require("chalk"));
const external_editor_1 = require("external-editor");
const core_1 = require("@inquirer/core");
exports.default = (0, core_1.createPrompt)((config, done) => {
const { waitForUseInput = true } = config;
const { waitForUseInput = true, validate = () => true } = config;
const [status, setStatus] = (0, core_1.useState)('pending');

@@ -30,3 +33,3 @@ const [value, setValue] = (0, core_1.useState)(config.default || '');

setStatus('loading');
const isValid = yield config.validate(answer);
const isValid = yield validate(answer);
if (isValid === true) {

@@ -33,0 +36,0 @@ setError(undefined);

@@ -11,8 +11,11 @@ "use strict";

};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const chalk_1 = require("chalk");
const chalk_1 = __importDefault(require("chalk"));
const external_editor_1 = require("external-editor");
const core_1 = require("@inquirer/core");
exports.default = (0, core_1.createPrompt)((config, done) => {
const { waitForUseInput = true } = config;
const { waitForUseInput = true, validate = () => true } = config;
const [status, setStatus] = (0, core_1.useState)('pending');

@@ -30,3 +33,3 @@ const [value, setValue] = (0, core_1.useState)(config.default || '');

setStatus('loading');
const isValid = yield config.validate(answer);
const isValid = yield validate(answer);
if (isValid === true) {

@@ -33,0 +36,0 @@ setError(undefined);

@@ -1,8 +0,8 @@

import { type AsyncPromptConfig } from '@inquirer/core';
type EditorConfig = AsyncPromptConfig & {
default?: string;
postfix?: string;
waitForUseInput?: boolean;
};
declare const _default: import("@inquirer/type").Prompt<string, EditorConfig>;
declare const _default: import("@inquirer/type").Prompt<string, {
message: string | Promise<string> | (() => Promise<string>);
default?: string | undefined;
postfix?: string | undefined;
waitForUseInput?: boolean | undefined;
validate?: ((value: string) => string | boolean | Promise<string | boolean>) | undefined;
}>;
export default _default;
{
"name": "@inquirer/editor",
"version": "1.2.9",
"version": "1.2.10",
"description": "Inquirer multiline editor prompt",

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

"dependencies": {
"@inquirer/core": "^4.1.0",
"@inquirer/type": "^1.1.3",
"@inquirer/core": "^5.0.0",
"@inquirer/type": "^1.1.4",
"chalk": "^4.1.2",

@@ -86,3 +86,3 @@ "external-editor": "^3.1.0"

},
"gitHead": "f5c544a8ded1c7dfb6ac8364759955e8f2ecfb0c"
"gitHead": "c2d1c5fdfd1029f78351fb04e06f1cfb29d55bb6"
}

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