mkdocs: Pages encoded UTF-8 with BOM not rendered correctly
Hello,
I have a simple index markdown file:
# Project
## Overview
And it fails to render correctly in any theme.
Cinder

ReadTheDocs

Am I doing something wrong? If I change it to a level 2 heading, the same thing happens.
I can workaround it by placing a blank line at the start of the file, but then the heading appears too low:

Thanks.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 21 (14 by maintainers)
Commits related to this issue
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to waylan/mkdocs by waylan 7 years ago
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to waylan/mkdocs by waylan 7 years ago
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to waylan/mkdocs by waylan 7 years ago
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to waylan/mkdocs by waylan 7 years ago
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to waylan/mkdocs by waylan 7 years ago
- Open files with `utf-8-sig` to account for BOM. Python simply discards the BOM with `utf-8-sig`. This way, users of Microsoft text editors can have their files properly parsered. In all other ways be... — committed to mkdocs/mkdocs by waylan 7 years ago
Oh course that’s what Windows is doing 🤦♂️. That’s such a Windows thing to do.
Well, that’s good news. At least the issue has been clearly identified. As far as I know, MkDocs doesn’t allow you to specify encoding, so as long as you use proper UTF-8, you should be fine. Maybe this should be more clearly stated in the documentation if it isn’t already.