Skip to content

Commit

Permalink
Docs: Make sure reference section is always added (airbytehq#34770)
Browse files Browse the repository at this point in the history
  • Loading branch information
Joe Reuter authored and jatinyadav-cc committed Feb 21, 2024
1 parent 2374a5c commit f0160d6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docusaurus/src/remark/specDecoration.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,13 @@ async function injectDefaultAirbyteLibSection(vfile, ast) {
});
}
});
if (!added) {
throw new Error(`Could not find a changelog heading in ${vfile.path} to add the default airbyte-lib section. This connector won't have a reference section. Make sure there is either a ## Changelog section or add a manual reference section.`);
}
}

function isChangelogHeading(node) {
return node.depth === 2 && node.children.length === 1 && node.children[0].value === "Changelog";
return node.depth === 2 && node.children.length === 1 && node.children[0].value.toLowerCase() === "changelog";
}


Expand Down

0 comments on commit f0160d6

Please sign in to comment.