New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@types/inquirer-fuzzy-path

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/inquirer-fuzzy-path

TypeScript definitions for inquirer-fuzzy-path

2.3.9
ts4.5
ts4.6
ts4.7
ts4.8
ts4.9
ts5.0
ts5.1
ts5.2
ts5.3
ts5.4
ts5.5
ts5.6
ts5.7
ts5.8
ts5.9
latest
Source
npm
Version published
Weekly downloads
7.8K
38.53%
Maintainers
1
Weekly downloads
 
Created
Source

Installation

npm install --save @types/inquirer-fuzzy-path

Summary

This package contains type definitions for inquirer-fuzzy-path (https://github.com/adelsz/inquirer-fuzzy-path).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/inquirer-fuzzy-path.

index.d.ts

import { Answers, KeyUnion, QuestionCollection } from "inquirer";
import { AutocompleteQuestionOptions } from "inquirer-autocomplete-prompt";
import InquirerAutocomplete = require("inquirer-autocomplete-prompt");
import { Interface as ReadlineInterface } from "readline";

export = InquirerFuzzyPath;

/**
 * Provides the functionality to create a new Inquirer plugin
 */
declare class InquirerFuzzyPath<T extends Answers> extends InquirerAutocomplete<T> {
    /**
     * Create new InquirerFuzzyPath
     *
     * @param questions
     * The questions to prompt
     * @param rl
     * The readline interface
     * @param answers
     * The currently supplied answers
     */
    constructor(questions: QuestionCollection<T>, rl: ReadlineInterface, answers: Answers);

    /**
     * Curate list of choices.
     *
     * @param searchTerm
     * The term to search for
     */
    search(searchTerm: string): Promise<void>;

    /**
     * When user presses `enter` key
     *
     * @param line
     * The input on the line.
     */
    onSubmit(line: string): void;
}

/**
 * Provides inquirer prompt options for type `InquirerFuzzyPath`.
 */
declare namespace InquirerFuzzyPath {
    /**
     * Provides options for a question of type `InquirerFuzzyPath`.
     *
     * @template T
     * The type of the answers.
     */
    interface FuzzyPathQuestionOptions<T extends Answers = Answers>
        extends Partial<Omit<AutocompleteQuestionOptions<T>, "type">>
    {
        /**
         * The key to save the answer to the answers-hash.
         */
        type: "fuzzypath";

        /**
         * The key to save the answer to the answers-hash.
         */
        name: KeyUnion<T>;

        /**
         * The root search directory, default to ".".
         */
        rootPath?: string | undefined;

        /**
         * A function to exclude some paths from the file-system scan.
         */
        excludePath?: ((path: string) => boolean) | undefined;

        /**
         * A function to exclude some paths from the final list.
         */
        excludeFilter?: ((path: string) => boolean) | undefined;

        /**
         * A string to specify the type of nodes to display, default to "any".
         */
        itemType?: "any" | "directory" | "file" | undefined;

        /**
         * An integer (>= 0) to limit the depth of sub-folders to scan,
         * undefined means infinite.
         */
        depthLimit?: number | undefined;
    }
}

Additional Details

Credits

These definitions were written by 迷子 (Maiko Tan).

FAQs

Package last updated on 07 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts