Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plz support definition for typescript users #46

Open
webhacking opened this issue Sep 19, 2019 · 3 comments
Open

Plz support definition for typescript users #46

webhacking opened this issue Sep 19, 2019 · 3 comments

Comments

@webhacking
Copy link

I could not use it at all because of one of my compilation options
So I made it myself. I hope others don't have the same issues as me.

import { Locale } from 'locale';

export declare module 'locale' {
  interface Locale {
    code: string;
    language: string;
    country: string;
    normalized: string;
    score: number;
  }
  declare function Locales(language: string): Locale[];
}
@florrain
Copy link
Owner

florrain commented Sep 19, 2019

Hi there, I don't use TypeScript at all but is there anything the repo could include to better support it?

I'm guessing your snippet is fixing it, but can you describe what it is solving. And two would you be up for a PR?

@forivall
Copy link

forivall commented Oct 3, 2019

You can also submit a PR to https://github.com/DefinitelyTyped/DefinitelyTyped/

@forivall
Copy link

forivall commented Mar 6, 2020

I wrote one DefinitelyTyped/DefinitelyTyped#42968

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants