simov / markdown-viewer

Markdown Viewer / Browser Extension
MIT License
1.01k stars 131 forks source link

Frontmatter missing in raw markdown view #226

Closed vondravl closed 2 months ago

vondravl commented 6 months ago

Hi, not sure if my question is not out of scope of this extension. Anyway I thought I'll try to ask. I wonder if it would be possible to view this part of md file. Right now it is skipped. In Obisidian it is properties part.

---
category: 
author: 
title: 
source: 
published:
topics: 
tags: 
---
simov commented 5 months ago

You can switch to the raw markdown at any time and have a look at the file metadata. Also the title property is being used to set the document title of your rendered markdown file.

Other than that I have no idea where it should be the most appropriate place to render the rest of those properties since right now the extension has only a sidebar for the table of contents, and the rest is just the content itself.

vondravl commented 5 months ago

Could you just advice me how to switch between Raw and Markdown? Trying to find that, so far I've done that by viewing page source. Not sure if there is some other way to do that.

simov commented 5 months ago

First pin the extension to you toolbar for easier access and then:

view-raw-md

vondravl commented 5 months ago

Actually I knew about that. But that is not showing properties either. Having this text:

---
category:
author:
title: 
source: 
clipped: 
published: 
topics: 
tags: 
---

First paragraph of text

This is what I see: image So Properties are skipped as well as in html view.

Or is it broken only on my side?

simov commented 5 months ago

No, you just found a bug, congratulations, it should have been there. It will be fixed in the next release.

vondravl commented 5 months ago

Thank you very much.

Think about some buymeacoffee or support development of the extension page. I think I won't be alone who would like to support you for work done ;)

simov commented 2 months ago

This issue got fixed in v5.3, also now the raw markdown view is syntax highlighted if you have the syntax option enabled in the Content tab.