wojtekmaj / get-user-locale

A function that returns user's locale as an IETF language tag, based on all available sources.
MIT License
58 stars 9 forks source link

Update type declarations #19

Closed sebinemeth closed 2 years ago

sebinemeth commented 2 years ago

Fix missing type declaration of options.

index.d.ts

declare module 'get-user-locale' {
  export type UserLocaleOptions = {
    fallbackLocale?: string,
    useFallbackLocale?: boolean,
  }
  export function getUserLocale(options?: UserLocaleOptions): string;
  export function getUserLocales(options?: UserLocaleOptions): string[];
  export default getUserLocale;
}
sebinemeth commented 2 years ago

@wojtekmaj the type declarations were left out of the previous release. Please if you have some time, review and publish it. Thanks!

wojtekmaj commented 2 years ago

Thanks!