Installation
npm install --save @types/parse-gitignore
Summary
This package contains type definitions for parse-gitignore (https://github.com/jonschlinkert/parse-gitignore).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/parse-gitignore.
declare function gitignore(input: string | Buffer): string[];
declare namespace gitignore {
function parse(input: string | Buffer, fn?: FormatLine): State;
function format(section: Section): string;
function stringify(sections: Section[], fn?: typeof format): string;
interface State {
patterns: string[];
sections: Section[];
}
interface Section {
readonly name: string;
readonly patterns: string[];
}
interface FormatLine {
(line: string, section?: Section, state?: State): string;
}
}
export = gitignore;
Additional Details
- Last updated: Tue, 07 Nov 2023 09:09:39 GMT
- Dependencies: @types/node
Credits
These definitions were written by Piotr Błażejewicz.