triangle-types 1.0.259 → 1.0.260
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -5,7 +5,7 @@ export declare class WebDocument {
|
|
|
5
5
|
readonly title: string;
|
|
6
6
|
readonly description: string;
|
|
7
7
|
readonly time: string;
|
|
8
|
-
readonly snippets
|
|
8
|
+
readonly snippets?: string[];
|
|
9
9
|
readonly s3_id_html?: string;
|
|
10
10
|
readonly s3_id_txt?: string;
|
|
11
11
|
constructor(web_document: WebDocument);
|
|
@@ -30,7 +30,7 @@ export class WebDocument {
|
|
|
30
30
|
typeof web_document.title === "string" &&
|
|
31
31
|
typeof web_document.description === "string" &&
|
|
32
32
|
typeof web_document.time === "string" &&
|
|
33
|
-
Array.isArray(web_document.snippets) && web_document.snippets.every((snippet) => typeof snippet === "string") &&
|
|
33
|
+
(web_document.snippets === undefined || Array.isArray(web_document.snippets) && web_document.snippets.every((snippet) => typeof snippet === "string")) &&
|
|
34
34
|
(web_document.s3_id_html === undefined || typeof web_document.s3_id_html === "string") &&
|
|
35
35
|
(web_document.s3_id_txt === undefined || typeof web_document.s3_id_txt === "string"));
|
|
36
36
|
}
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@ export class WebDocument {
|
|
|
5
5
|
readonly title : string
|
|
6
6
|
readonly description : string
|
|
7
7
|
readonly time : string
|
|
8
|
-
readonly snippets : string[]
|
|
8
|
+
readonly snippets? : string[]
|
|
9
9
|
readonly s3_id_html? : string
|
|
10
10
|
readonly s3_id_txt? : string
|
|
11
11
|
|
|
@@ -33,7 +33,7 @@ export class WebDocument {
|
|
|
33
33
|
typeof web_document.title === "string" &&
|
|
34
34
|
typeof web_document.description === "string" &&
|
|
35
35
|
typeof web_document.time === "string" &&
|
|
36
|
-
Array.isArray(web_document.snippets) && web_document.snippets.every((snippet : any) => typeof snippet === "string") &&
|
|
36
|
+
(web_document.snippets === undefined || Array.isArray(web_document.snippets) && web_document.snippets.every((snippet : any) => typeof snippet === "string")) &&
|
|
37
37
|
(web_document.s3_id_html === undefined || typeof web_document.s3_id_html === "string") &&
|
|
38
38
|
(web_document.s3_id_txt === undefined || typeof web_document.s3_id_txt === "string")
|
|
39
39
|
)
|