-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
2,250 additions
and
678 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
package.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
// flow-typed signature: 7814bad223d2abb492841c50a587c50a | ||
// flow-typed version: <<STUB>>/enzyme-adapter-react-16_v^1.1.0/flow_v0.56.0 | ||
|
||
/** | ||
* This is an autogenerated libdef stub for: | ||
* | ||
* 'enzyme-adapter-react-16' | ||
* | ||
* Fill this stub out by replacing all the `any` types. | ||
* | ||
* Once filled out, we encourage you to share your work with the | ||
* community by sending a pull request to: | ||
* https://github.com/flowtype/flow-typed | ||
*/ | ||
|
||
declare module 'enzyme-adapter-react-16' { | ||
declare module.exports: any; | ||
} | ||
|
||
/** | ||
* We include stubs for each file inside this npm package in case you need to | ||
* require those files directly. Feel free to delete any files that aren't | ||
* needed. | ||
*/ | ||
declare module 'enzyme-adapter-react-16/build/findCurrentFiberUsingSlowPath' { | ||
declare module.exports: any; | ||
} | ||
|
||
declare module 'enzyme-adapter-react-16/build/index' { | ||
declare module.exports: any; | ||
} | ||
|
||
declare module 'enzyme-adapter-react-16/build/ReactSixteenAdapter' { | ||
declare module.exports: any; | ||
} | ||
|
||
declare module 'enzyme-adapter-react-16/src/findCurrentFiberUsingSlowPath' { | ||
declare module.exports: any; | ||
} | ||
|
||
declare module 'enzyme-adapter-react-16/src/index' { | ||
declare module.exports: any; | ||
} | ||
|
||
declare module 'enzyme-adapter-react-16/src/ReactSixteenAdapter' { | ||
declare module.exports: any; | ||
} | ||
|
||
// Filename aliases | ||
declare module 'enzyme-adapter-react-16/build/findCurrentFiberUsingSlowPath.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/build/findCurrentFiberUsingSlowPath'>; | ||
} | ||
declare module 'enzyme-adapter-react-16/build/index.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/build/index'>; | ||
} | ||
declare module 'enzyme-adapter-react-16/build/ReactSixteenAdapter.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/build/ReactSixteenAdapter'>; | ||
} | ||
declare module 'enzyme-adapter-react-16/src/findCurrentFiberUsingSlowPath.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/src/findCurrentFiberUsingSlowPath'>; | ||
} | ||
declare module 'enzyme-adapter-react-16/src/index.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/src/index'>; | ||
} | ||
declare module 'enzyme-adapter-react-16/src/ReactSixteenAdapter.js' { | ||
declare module.exports: $Exports<'enzyme-adapter-react-16/src/ReactSixteenAdapter'>; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,178 @@ | ||
// flow-typed signature: 4eed8da2dc730dc33e7710b465eaa44b | ||
// flow-typed version: cc7a557b34/prettier_v1.x.x/flow_>=v0.56.x | ||
|
||
declare module "prettier" { | ||
declare type AST = Object; | ||
declare type Doc = Object; | ||
declare type FastPath = Object; | ||
|
||
declare type PrettierParserName = | ||
| "babylon" | ||
| "flow" | ||
| "typescript" | ||
| "postcss" | ||
| "css" | ||
| "less" | ||
| "scss" | ||
| "json" | ||
| "graphql" | ||
| "markdown" | ||
| "vue"; | ||
|
||
declare type PrettierParser = { | ||
[name: PrettierParserName]: (text: string, options?: Object) => AST | ||
}; | ||
|
||
declare type CustomParser = ( | ||
text: string, | ||
parsers: PrettierParser, | ||
options: Options | ||
) => AST; | ||
|
||
declare type Options = {| | ||
printWidth?: number, | ||
tabWidth?: number, | ||
useTabs?: boolean, | ||
semi?: boolean, | ||
singleQuote?: boolean, | ||
trailingComma?: "none" | "es5" | "all", | ||
bracketSpacing?: boolean, | ||
jsxBracketSameLine?: boolean, | ||
arrowParens?: "avoid" | "always", | ||
rangeStart?: number, | ||
rangeEnd?: number, | ||
parser?: PrettierParserName | CustomParser, | ||
filepath?: string, | ||
requirePragma?: boolean, | ||
insertPragma?: boolean, | ||
proseWrap?: "always" | "never" | "preserve", | ||
plugins?: Array<string | Plugin> | ||
|}; | ||
|
||
declare type Plugin = { | ||
languages: SupportLanguage, | ||
parsers: { [parserName: string]: Parser }, | ||
printers: { [astFormat: string]: Printer } | ||
}; | ||
|
||
declare type Parser = { | ||
parse: ( | ||
text: string, | ||
parsers: { [parserName: string]: Parser }, | ||
options: Object | ||
) => AST, | ||
astFormat: string | ||
}; | ||
|
||
declare type Printer = { | ||
print: ( | ||
path: FastPath, | ||
options: Object, | ||
print: (path: FastPath) => Doc | ||
) => Doc, | ||
embed: ( | ||
path: FastPath, | ||
print: (path: FastPath) => Doc, | ||
textToDoc: (text: string, options: Object) => Doc, | ||
options: Object | ||
) => ?Doc | ||
}; | ||
|
||
declare type CursorOptions = {| | ||
cursorOffset: number, | ||
printWidth?: $PropertyType<Options, "printWidth">, | ||
tabWidth?: $PropertyType<Options, "tabWidth">, | ||
useTabs?: $PropertyType<Options, "useTabs">, | ||
semi?: $PropertyType<Options, "semi">, | ||
singleQuote?: $PropertyType<Options, "singleQuote">, | ||
trailingComma?: $PropertyType<Options, "trailingComma">, | ||
bracketSpacing?: $PropertyType<Options, "bracketSpacing">, | ||
jsxBracketSameLine?: $PropertyType<Options, "jsxBracketSameLine">, | ||
arrowParens?: $PropertyType<Options, "arrowParens">, | ||
parser?: $PropertyType<Options, "parser">, | ||
filepath?: $PropertyType<Options, "filepath">, | ||
requirePragma?: $PropertyType<Options, "requirePragma">, | ||
insertPragma?: $PropertyType<Options, "insertPragma">, | ||
proseWrap?: $PropertyType<Options, "proseWrap">, | ||
plugins?: $PropertyType<Options, "plugins"> | ||
|}; | ||
|
||
declare type CursorResult = {| | ||
formatted: string, | ||
cursorOffset: number | ||
|}; | ||
|
||
declare type ResolveConfigOptions = {| | ||
useCache?: boolean, | ||
config?: string, | ||
editorconfig?: boolean | ||
|}; | ||
|
||
declare type SupportLanguage = { | ||
name: string, | ||
since: string, | ||
parsers: Array<string>, | ||
group?: string, | ||
tmScope: string, | ||
aceMode: string, | ||
codemirrorMode: string, | ||
codemirrorMimeType: string, | ||
aliases?: Array<string>, | ||
extensions: Array<string>, | ||
filenames?: Array<string>, | ||
linguistLanguageId: number, | ||
vscodeLanguageIds: Array<string> | ||
}; | ||
|
||
declare type SupportOption = {| | ||
since: string, | ||
type: "int" | "boolean" | "choice" | "path", | ||
deprecated?: string, | ||
redirect?: SupportOptionRedirect, | ||
description: string, | ||
oppositeDescription?: string, | ||
default: SupportOptionValue, | ||
range?: SupportOptionRange, | ||
choices?: SupportOptionChoice | ||
|}; | ||
|
||
declare type SupportOptionRedirect = {| | ||
options: string, | ||
value: SupportOptionValue | ||
|}; | ||
|
||
declare type SupportOptionRange = {| | ||
start: number, | ||
end: number, | ||
step: number | ||
|}; | ||
|
||
declare type SupportOptionChoice = {| | ||
value: boolean | string, | ||
description?: string, | ||
since?: string, | ||
deprecated?: string, | ||
redirect?: SupportOptionValue | ||
|}; | ||
|
||
declare type SupportOptionValue = number | boolean | string; | ||
|
||
declare type SupportInfo = {| | ||
languages: Array<SupportLanguage>, | ||
options: Array<SupportOption> | ||
|}; | ||
|
||
declare type Prettier = {| | ||
format: (source: string, options?: Options) => string, | ||
check: (source: string, options?: Options) => boolean, | ||
formatWithCursor: (source: string, options: CursorOptions) => CursorResult, | ||
resolveConfig: { | ||
(filePath: string, options?: ResolveConfigOptions): Promise<?Options>, | ||
sync(filePath: string, options?: ResolveConfigOptions): Promise<?Options> | ||
}, | ||
clearConfigCache: () => void, | ||
getSupportInfo: (version?: string) => SupportInfo | ||
|}; | ||
|
||
declare export default Prettier; | ||
} |
Oops, something went wrong.