In simpl-schema, overload schema() method. (#37871)

This commit is contained in:
Chiciuc Nicușor 2019-08-24 02:06:46 +03:00 committed by Sheetal Nandi
parent 30dd1a6359
commit 043ea4e706

View File

@ -3,6 +3,7 @@
// Definitions by: Andreas Richter <https://github.com/arichter83>
// Qkramer <https://github.com/Qkramer>
// Deskoh <https://github.com/deskoh>
// Nicusor Chiciuc <https://github.com/nicu-chiciuc>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export interface ValidationContext extends SimpleSchemaValidationContextStatic {
@ -122,7 +123,8 @@ interface SimpleSchemaStatic {
pick(...fields: string[]): SimpleSchemaStatic;
omit(...fields: string[]): SimpleSchemaStatic;
clean(doc: any, options?: CleanOption): any;
schema(key?: string): SchemaDefinition | SchemaDefinition[];
schema(key: string): SchemaDefinition;
schema(): SchemaDefinition[];
getDefinition(key: string, propList?: any, functionContext?: any): any;
keyIsInBlackBox(key: string): boolean;
labels(labels: {[key: string]: string}): void;