]> git.kaiwu.me - njs.git/commitdiff
Types: mark String.bytesFrom() in as deprecated.
authorJakub Jirutka <jakub@jirutka.cz>
Mon, 19 Oct 2020 19:42:01 +0000 (21:42 +0200)
committerJakub Jirutka <jakub@jirutka.cz>
Mon, 19 Oct 2020 19:42:01 +0000 (21:42 +0200)
src/ts/njs_core.d.ts

index db0b45c27f19d8ddd178dc2366e0e9128c122f1e..8783b3bee04342c7153a1df417a9e6096ef32ffb 100644 (file)
@@ -3,10 +3,14 @@ type BufferEncoding = "utf8" | "hex" | "base64" | "base64url";
 interface StringConstructor {
     /**
      * Creates a byte string from an encoded string.
+     *
+     * @deprecated will be removed in the future.
      */
     bytesFrom(bytes: string, encoding: Exclude<BufferEncoding, "utf8">): NjsByteString;
     /**
      * Creates a byte string from an array that contains octets.
+     *
+     * @deprecated will be removed in the future.
      */
     bytesFrom(bytes: Array<number>): NjsByteString;
 }