1 | # Installation
|
2 | > `npm install --save @types/pretty-quick`
|
3 |
|
4 | # Summary
|
5 | This package contains type definitions for pretty-quick (https://github.com/azz/pretty-quick#readme).
|
6 |
|
7 | # Details
|
8 | Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pretty-quick.
|
9 | ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/pretty-quick/index.d.ts)
|
10 | ````ts
|
11 | // Type definitions for pretty-quick 3.1
|
12 | // Project: https://github.com/azz/pretty-quick#readme
|
13 | // Definitions by: Piotr Błażejewicz <https://github.com/peterblazejewicz>
|
14 | // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
15 | // Minimum TypeScript Version: 4.2
|
16 |
|
17 | import { ResolveConfigOptions } from 'prettier';
|
18 |
|
19 | declare namespace prettyQuick {
|
20 | interface Options {
|
21 | config?: ResolveConfigOptions | undefined;
|
22 | since?: string | undefined;
|
23 | /** @default false */
|
24 | staged?: boolean | undefined;
|
25 | pattern?: string | string[] | undefined;
|
26 | /** @default true */
|
27 | restage?: boolean | undefined;
|
28 | /**
|
29 | * @default 'master' | 'default'
|
30 | */
|
31 | branch?: string | undefined;
|
32 | bail?: boolean | undefined;
|
33 | check?: boolean | undefined;
|
34 | ignorePath?: string | undefined;
|
35 | verbose?: boolean | undefined;
|
36 | onFoundSinceRevision?: ((name: string, revision: string) => void) | undefined;
|
37 | onFoundChangedFiles?: ((changedFiles: string[]) => void) | undefined;
|
38 | onPartiallyStagedFile?: ((file: string) => void) | undefined;
|
39 | onExamineFile?: ((file: string) => void) | undefined;
|
40 | onCheckFile?: ((file: string, isFormatted: boolean) => void) | undefined;
|
41 | onWriteFile?: ((file: string) => void) | undefined;
|
42 | // ...args support
|
43 | [key: string]: any;
|
44 | }
|
45 |
|
46 | interface Results {
|
47 | readonly success: boolean;
|
48 | readonly errors: string[];
|
49 | }
|
50 | }
|
51 |
|
52 | /**
|
53 | * Runs Prettier on your changed files.
|
54 | * Supported source control managers:
|
55 | * * Git
|
56 | * * Mercurial
|
57 | */
|
58 | declare function prettyQuick(currentDirectory: string, options?: prettyQuick.Options): prettyQuick.Results;
|
59 |
|
60 | export = prettyQuick;
|
61 |
|
62 | ````
|
63 |
|
64 | ### Additional Details
|
65 | * Last updated: Thu, 12 May 2022 18:31:40 GMT
|
66 | * Dependencies: [@types/prettier](https://npmjs.com/package/@types/prettier)
|
67 | * Global values: none
|
68 |
|
69 | # Credits
|
70 | These definitions were written by [Piotr Błażejewicz](https://github.com/peterblazejewicz).
|
71 |
|
\ | No newline at end of file |