code: function addSourceInstanceName(
    { node, getNode, loadNodeContent, actions, createNodeId, reporter },
    pluginOptions
  ) {
    const { createNodeField } = actions;
  
    const parent = getNode(node.parent);
  
    const sourceInstanceName =
      parent && parent.sourceInstanceName ? parent.sourceInstanceName : 'unknown';
  
    // Add node field
    createNodeField({
      node,
      name: 'sourceName',
      value: sourceInstanceName
    });
  
    // console.error('adding', sourceInstanceName, node.fields.sourceInstanceName)
  
    // if (!parent) {
    //   // Node has already been processed.
    //   console.error('Ocular markdown node has no parent', JSON.stringify(node.parent), JSON.stringify(node.sourceInstanceName), node.relativePath);
    //   return;
    // }
  
    if (parent) {
      addMissingFrontmatter(node, sourceInstanceName);
    }
  }
docs: Ensure sourceInstanceName (added by gatsby-source-filsystem config options) is present on nodes generated by gatsby-transform-remark