Simre1 / neorg-haskell-parser

MIT License
91 stars 7 forks source link

Ignore empty lines when calculating tag indentation #8

Closed JCapucho closed 2 years ago

JCapucho commented 2 years ago

The tag parsing code checks that all of the tag's content is properly indented otherwise returns Nothing. But the code wasn't taking into account lines that were empty or made only of whitespace characters and some code includes these lines and they are almost never indented.

This is fixed by filtering out lines that are empty or made only of whitespace characters when calculating the minimum content indentation.

Fixes #7