mirror of
https://github.com/LukeHagar/unicorn-utterances.git
synced 2025-12-09 21:07:49 +00:00
Add comments about changes, improve config file support of multi author
This commit is contained in:
@@ -133,7 +133,17 @@ module.exports = {
|
||||
url: nodeUrl,
|
||||
guid: nodeUrl,
|
||||
custom_elements: [
|
||||
{"dc:creator": frontmatter.authors.name }, //changed
|
||||
/**
|
||||
* We chose `dc:creator` in order to avoid having
|
||||
* to list contact information from our contributors,
|
||||
* as `dc:creator`
|
||||
*
|
||||
* FIXME: This does not have the functionality we'd expect
|
||||
* it only lists the last author's name
|
||||
*
|
||||
* @see https://github.com/dylang/node-rss/issues/92
|
||||
*/
|
||||
{"dc:creator": frontmatter.authors.map(author => author.name) },
|
||||
{comments: `${nodeUrl}#disqus_thread`}
|
||||
],
|
||||
}})
|
||||
@@ -198,7 +208,7 @@ module.exports = {
|
||||
{
|
||||
name: "en",
|
||||
// A function for filtering nodes. () => true by default
|
||||
filterNodes: node => !!node.frontmatter && !!node.frontmatter.authors, //changed
|
||||
filterNodes: node => !!node.frontmatter && !!node.frontmatter.authors,
|
||||
},
|
||||
],
|
||||
// Fields to index. If store === true value will be stored in index file.
|
||||
@@ -226,7 +236,14 @@ module.exports = {
|
||||
excerpt: node => node.excerpt,
|
||||
description: node => node.frontmatter.description,
|
||||
slug: node => node.fields.slug,
|
||||
authors: node => node.frontmatter.authors.name, //changed
|
||||
/**
|
||||
* FIXME: This does not work the way we'd want. We want the name
|
||||
* the author rather than the username, but the node is not
|
||||
* populated
|
||||
*
|
||||
* @see https://github.com/humanseelabs/gatsby-plugin-lunr/issues/24
|
||||
*/
|
||||
authors: node => node.frontmatter.authors.join(', '),
|
||||
tags: node => node.frontmatter.tags,
|
||||
},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user