Skip to content

Commit

Permalink
fix: don't remove empty lines
Browse files Browse the repository at this point in the history
  • Loading branch information
razortanmayshah committed Apr 2, 2024
1 parent 2fcfdeb commit d14a0b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion build-search.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const build = async (config) => {
// trim the content to remove extra empty lines and spaces
// if content is not trimmed, then this results in incorrect interpretation of indentation resulting
// resulting in errors like adding codeblocks whenver indentation > 3 etc.
const trimmedContent = content.split('\n').filter(line => Boolean(line.trim())).map(line => line.trim()).join('\n')
const trimmedContent = content.split('\n').map(line => line.trim()).join('\n')
const parsedContent = markdown(trimmedContent, config);
const parsedContentWithFrontmatter = {
...parsedContent,
Expand Down

0 comments on commit d14a0b5

Please sign in to comment.