mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 23:07:06 +00:00
Node-Polyglot: Added method has to interface
This commit is contained in:
Vendored
+2
@@ -38,6 +38,8 @@ declare class Polyglot {
|
||||
locale(): string;
|
||||
|
||||
locale(locale: string): void;
|
||||
|
||||
has(phrase: string): boolean;
|
||||
}
|
||||
|
||||
export = Polyglot;
|
||||
|
||||
@@ -46,7 +46,10 @@ function translate(): void {
|
||||
polyglot.t("i_like_to_write_in_language", {
|
||||
_: "I like to write in %{language}.",
|
||||
language: "Javascript"
|
||||
});
|
||||
});
|
||||
|
||||
polyglot.has("hello");
|
||||
polyglot.has("world");
|
||||
|
||||
polyglot.replace({
|
||||
"hello": "hey",
|
||||
|
||||
Reference in New Issue
Block a user