Installation
npm install --save @types/langs
Summary
This package contains type definitions for langs (https://github.com/adlawson/langs.js#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/langs.
index.d.ts
declare namespace langs {
type Type = 1 | 2 | 3 | "1" | "2" | "2T" | "2B" | "3" | "name" | "local";
interface Language {
name: string;
local: string;
"1": string;
"2": string;
"2T": string;
"2B": string;
"3": string;
}
interface Langs {
all: () => Language[];
has: (type: Type, val: string) => boolean;
codes: (type: Exclude<Type, "name" | "local">) => string[];
names: (local?: boolean) => string[];
where: (type: Type, val: string) => Language | undefined;
}
}
declare const langs: langs.Langs;
export = langs;
Additional Details
- Last updated: Wed, 07 Feb 2024 06:35:28 GMT
- Dependencies: none
Credits
These definitions were written by Orgad Shaneh.