Closed RyotaUshio closed 1 year ago
This is a very simple error, but prevented any markdown file that has its first heading at line zero, for example:
# Heading > [!NOTE] > Hello, world
because this if condition is always satisfied as long as there is at least one heading. https://github.com/blacksmithgu/datacore/blob/5fdeb17522770fa75b6a4083c6d850e83c13a6b9/src/index/import/markdown.ts#L67
if
In this case, the section with $ordinal == 0 should not be created, but it is created and it overwrites the original section with $ordinal == 1.
$ordinal == 0
$ordinal == 1
This is a very simple error, but prevented any markdown file that has its first heading at line zero, for example:
because this
if
condition is always satisfied as long as there is at least one heading. https://github.com/blacksmithgu/datacore/blob/5fdeb17522770fa75b6a4083c6d850e83c13a6b9/src/index/import/markdown.ts#L67In this case, the section with
$ordinal == 0
should not be created, but it is created and it overwrites the original section with$ordinal == 1
.