Open ehartford opened 7 years ago
something like
declare namespace owaspPasswordStrengthTest {
interface TestRet {
errors : string[];
failedTests : number[];
passedTests : number[];
requiredTestErrors : string[];
optionalTestErrors : string[];
isPassphrase : boolean;
strong : boolean;
optionalTestsPassed : number;
}
interface Config {
allowPassphrases? : boolean;
maxLength? : number;
minLength? : number;
minPhraseLength? : number;
minOptionalTestsToPass? : number;
}
interface OwaspPasswordStrengthTest {
config : (params : Config) => void;
test : (password : string) => TestRet;
}
}
declare const owaspPST : owaspPasswordStrengthTest.OwaspPasswordStrengthTest;
export = owaspPST;
please, need typescript types for this