UNPKG

861 BTypeScriptView Raw
1/**
2 * @license
3 * Copyright (c) 2018 Google Inc. All rights reserved.
4 * This code may only be used under the BSD style license found at
5 * http://polymer.github.io/LICENSE.txt
6 * Code distributed by Google as part of this project is also
7 * subject to an additional IP rights grant found at
8 * http://polymer.github.io/PATENTS.txt
9 */
10
11declare module 'clang-format' {
12import {ChildProcess} from 'child_process';
13import * as stream from 'stream';
14import * as vinyl from 'vinyl';
15
16 type ClangFormatStyle = 'llvm'|'google'|'chromium'|'mozilla'|'webkit'|'file';
17
18 namespace ClangFormat {
19 function spawnClangFormat(args: string[], done: () => void, stdio: any):
20 ChildProcess;
21 }
22 function ClangFormat(
23 file: vinyl,
24 enc: string,
25 style: ClangFormatStyle,
26 done: (err?: any) => void): stream.Readable;
27
28 export = ClangFormat;
29}
\No newline at end of file