diff options
-rw-r--r-- | std/prettier/vendor/index.d.ts | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/std/prettier/vendor/index.d.ts b/std/prettier/vendor/index.d.ts index 354142746..606c87a98 100644 --- a/std/prettier/vendor/index.d.ts +++ b/std/prettier/vendor/index.d.ts @@ -2,7 +2,8 @@ // Project: https://github.com/prettier/prettier, https://prettier.io // Definitions by: Ika <https://github.com/ikatyang>, // Ifiok Jr. <https://github.com/ifiokjr>, -// Florian Keller <https://github.com/ffflorian> +// Florian Keller <https://github.com/ffflorian>, +// Sosuke Suzuki <https://github.com/sosukesuzuki> // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.8 @@ -257,6 +258,22 @@ export namespace resolveConfig { } /** + * `resolveConfigFile` can be used to find the path of the Prettier configuration file, + * that will be used when resolving the config (i.e. when calling `resolveConfig`). + * + * A promise is returned which will resolve to: + * + * - The path of the configuration file. + * - `null`, if no file was found. + * + * The promise will be rejected if there was an error parsing the configuration file. + */ +export function resolveConfigFile(filePath?: string): Promise<null | string>; +export namespace resolveConfigFile { + function sync(filePath?: string): null | string; +} + +/** * As you repeatedly call `resolveConfig`, the file system structure will be cached for performance. This function will clear the cache. * Generally this is only needed for editor integrations that know that the file system has changed since the last format took place. */ |