@docusaurus/plugin-content-blog 0.0.0-4656 → 0.0.0-4657

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.
package/lib/authors.js CHANGED
@@ -14,6 +14,7 @@ const AuthorsMapSchema = utils_validation_1.Joi.object().pattern(utils_validatio
14
14
  url: utils_validation_1.URISchema,
15
15
  imageURL: utils_validation_1.URISchema,
16
16
  title: utils_validation_1.Joi.string(),
17
+ email: utils_validation_1.Joi.string(),
17
18
  })
18
19
  .rename('image_url', 'imageURL')
19
20
  .or('name', 'imageURL')
package/lib/feed.js CHANGED
@@ -33,9 +33,7 @@ async function generateBlogFeed({ blogPosts, options, siteConfig, outDir, }) {
33
33
  copyright: feedOptions.copyright,
34
34
  });
35
35
  function toFeedAuthor(author) {
36
- // TODO ask author emails?
37
- // RSS feed requires email to render authors
38
- return { name: author.name, link: author.url };
36
+ return { name: author.name, link: author.url, email: author.email };
39
37
  }
40
38
  await (0, utils_1.mapAsyncSequential)(blogPosts, async (post) => {
41
39
  const { id, metadata: { title: metadataTitle, permalink, date, description, authors, tags, }, } = post;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docusaurus/plugin-content-blog",
3
- "version": "0.0.0-4656",
3
+ "version": "0.0.0-4657",
4
4
  "description": "Blog plugin for Docusaurus.",
5
5
  "main": "lib/index.js",
6
6
  "types": "src/plugin-content-blog.d.ts",
@@ -18,12 +18,12 @@
18
18
  },
19
19
  "license": "MIT",
20
20
  "dependencies": {
21
- "@docusaurus/core": "0.0.0-4656",
22
- "@docusaurus/logger": "0.0.0-4656",
23
- "@docusaurus/mdx-loader": "0.0.0-4656",
24
- "@docusaurus/utils": "0.0.0-4656",
25
- "@docusaurus/utils-common": "0.0.0-4656",
26
- "@docusaurus/utils-validation": "0.0.0-4656",
21
+ "@docusaurus/core": "0.0.0-4657",
22
+ "@docusaurus/logger": "0.0.0-4657",
23
+ "@docusaurus/mdx-loader": "0.0.0-4657",
24
+ "@docusaurus/utils": "0.0.0-4657",
25
+ "@docusaurus/utils-common": "0.0.0-4657",
26
+ "@docusaurus/utils-validation": "0.0.0-4657",
27
27
  "cheerio": "^1.0.0-rc.10",
28
28
  "feed": "^4.2.2",
29
29
  "fs-extra": "^10.0.1",
@@ -35,7 +35,7 @@
35
35
  "webpack": "^5.69.1"
36
36
  },
37
37
  "devDependencies": {
38
- "@docusaurus/types": "0.0.0-4656",
38
+ "@docusaurus/types": "0.0.0-4657",
39
39
  "escape-string-regexp": "^4.0.0"
40
40
  },
41
41
  "peerDependencies": {
@@ -45,5 +45,5 @@
45
45
  "engines": {
46
46
  "node": ">=14"
47
47
  },
48
- "gitHead": "9d3c7ee0e8413fe481c1f1be202fd3ec76efb087"
48
+ "gitHead": "dd99a15e9275f65126517c0cc4988553508fdb69"
49
49
  }
package/src/authors.ts CHANGED
@@ -24,6 +24,7 @@ const AuthorsMapSchema = Joi.object<AuthorsMap>().pattern(
24
24
  url: URISchema,
25
25
  imageURL: URISchema,
26
26
  title: Joi.string(),
27
+ email: Joi.string(),
27
28
  })
28
29
  .rename('image_url', 'imageURL')
29
30
  .or('name', 'imageURL')
package/src/feed.ts CHANGED
@@ -57,9 +57,7 @@ async function generateBlogFeed({
57
57
  });
58
58
 
59
59
  function toFeedAuthor(author: Author): FeedAuthor {
60
- // TODO ask author emails?
61
- // RSS feed requires email to render authors
62
- return {name: author.name, link: author.url};
60
+ return {name: author.name, link: author.url, email: author.email};
63
61
  }
64
62
 
65
63
  await mapAsyncSequential(blogPosts, async (post) => {
@@ -21,6 +21,7 @@ declare module '@docusaurus/plugin-content-blog' {
21
21
  imageURL?: string;
22
22
  url?: string;
23
23
  title?: string;
24
+ email?: string;
24
25
  }
25
26
 
26
27
  export type BlogPostFrontMatter = {