diff --git a/src/hmac-based/hmac-based.ts b/src/hmac-based/hmac-based.ts index 15e35fe..abefe6a 100644 --- a/src/hmac-based/hmac-based.ts +++ b/src/hmac-based/hmac-based.ts @@ -3,7 +3,7 @@ import { HotpValidateOptions, TotpConfig, ValidTotpConfig, -} from "../interfaces/otp.interface"; +} from "../interfaces"; import { generateConfig } from "../index"; import { Decode32 } from "../utils/encode"; import crypto from "crypto"; diff --git a/src/index.ts b/src/index.ts index b561c7d..7d8ca9b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -8,7 +8,7 @@ import { TotpConfig, UrlOptions, ValidTotpConfig, -} from "./interfaces/otp.interface"; +} from "./interfaces"; import { TimeBased } from "./time-based/time-based"; import { Encode32 } from "./utils/encode"; import crypto from "crypto"; @@ -79,3 +79,4 @@ export const generateUrl = ( export const Totp = new TimeBased(); export const Hotp = new HmacBased(); +export * from './interfaces'; \ No newline at end of file diff --git a/src/interfaces/otp.interface.ts b/src/interfaces/index.ts similarity index 100% rename from src/interfaces/otp.interface.ts rename to src/interfaces/index.ts diff --git a/src/time-based/generate-key.ts b/src/time-based/generate-key.ts index bdb1460..d0e6b2e 100644 --- a/src/time-based/generate-key.ts +++ b/src/time-based/generate-key.ts @@ -2,7 +2,7 @@ import { TotpConfig, TotpOptions, ValidTotpConfig, -} from "../interfaces/otp.interface"; +} from "../interfaces"; import { generateConfig, generateSecret, generateUrl } from "../index"; // https://github.com/google/google-authenticator/wiki/Key-Uri-Format diff --git a/src/time-based/time-based.ts b/src/time-based/time-based.ts index c7b2ccf..72ab862 100644 --- a/src/time-based/time-based.ts +++ b/src/time-based/time-based.ts @@ -5,7 +5,7 @@ import { TotpOptions, ValidTotpConfig, TotpValidateOptions, -} from "../interfaces/otp.interface"; +} from "../interfaces"; import { generateConfig } from "../index"; import { DEFAULT_TOTP_PERIOD } from "../utils/constants"; import { ValidationError } from "../utils/validation-error";