notion-api-js
Advanced tools
Comparing version 2.3.4 to 2.4.0
@@ -21,3 +21,3 @@ "use strict"; | ||
}, | ||
body: JSON.stringify(Object.assign({ limit, cursor: { stack }, chunkNumber }, body, { verticalColumns: false })), | ||
body: JSON.stringify(Object.assign({ cursor: { stack }, chunkNumber }, body, { limit, verticalColumns: false })), | ||
method: "POST" | ||
@@ -24,0 +24,0 @@ }) |
@@ -103,3 +103,5 @@ "use strict"; | ||
} | ||
const { format, properties } = ObjectList[0]; | ||
const { format, created_time, last_edited_time, properties } = ObjectList[0]; | ||
const created_datetime = new Date(created_time).toDateString(); | ||
const last_edited_datetime = new Date(last_edited_time).toDateString(); | ||
const title = (properties && properties.title && properties.title[0][0]) || ''; | ||
@@ -113,3 +115,5 @@ const cover = format && format.page_cover | ||
items, | ||
attributes: Object.assign({}, attributes, { title, slug: slugify_1.default(title, { lower: true }), cover, teaser: items | ||
attributes: Object.assign({}, attributes, { title, | ||
created_datetime, | ||
last_edited_datetime, slug: slugify_1.default(title, { lower: true }), cover, teaser: items | ||
.map(i => i | ||
@@ -116,0 +120,0 @@ .replace(/\[.{1,}\]: .{1,}/g, '') |
@@ -15,2 +15,4 @@ export declare type NotionObject = { | ||
content: Array<string>; | ||
created_time: number; | ||
last_edited_time: number; | ||
}; | ||
@@ -17,0 +19,0 @@ export declare type NotionResponse = { |
@@ -47,4 +47,4 @@ "use strict"; | ||
const values = Object.values(entries).map(value => { | ||
const { id, type, properties, format, content } = value.value; | ||
return { id, type, properties, format, content }; | ||
const { id, type, properties, format, content, created_time, last_edited_time } = value.value; | ||
return { id, type, properties, format, content, created_time, last_edited_time }; | ||
}); | ||
@@ -51,0 +51,0 @@ return helpers_1.default(values, this.options, htmlFormatter); |
{ | ||
"name": "notion-api-js", | ||
"version": "2.3.4", | ||
"version": "2.4.0", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "repository": "https://github.com/Frexeptabel/notion-api/", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19207
393