obsidian-columns
obsidian-columns copied to clipboard
[BUG: Internal] Code blocks don't render in Reader View
Describe the bug
When placing codeblocks in columns, they render just fine in Live Preview. But they disappear in reader view. This happens with every codeblock that isn't plain-text like code.
Steps To Reproduce
Add a codeblock for any other plugin as a column:
`````col
````col-md
flexGrow=1
===
```dataview
LIST FROM "Guides"
```
````
````col-md
flexGrow=1
===
>[!quote]
>We are what our thoughts have made us; so take care about what you think. Words are secondary. Thoughts live; they travel far.
>
> — Swami Vivekananda
````
`````
Expected behavior
Renders in both Live Preview and Reader view
Screenshots
Preview
Reader View
System Info
OS: Windows 10
Obsidian Version:
Plugin Version:
I have the same issue with a dataviewjs query that is displayed in live preview but not in reading view.
OS: Windows 11 Obsidian Version: v1.1.16 Obsidian Columns Plugin version: 1.4.0
````col-md
flexGrow=2
===
> [!abstract] `$= '[['+moment().format("YYYY-MM-DD")+'|Open Today\'s Note]]'` | `$= '[['+moment().format("YYYY-[W]ww")+'|Open this Week\'s Note]]'`
> [!faq]- MORGENROUTINE
> **06:30** **| I get ...**
```dataviewjs
dv.table(["Project", "ToDo", "Done", "Progress"],
dv.pages('"SPACES/projects"')
.sort(p => p.file.link)
.map(p => [
"[[" + p.file.name + "|" + p.aliases + "]]",
p.tasks_open,
p.tasks_done,
"<progress value='" + (p.tasks_done / p.tasks_total * 100) + "' max='100'></progress>"])
)
```
````
````col-md
flexGrow=1
===
> [!Example]- DASHBOARDS
> [[dash-areas|Area Dashboard]]
> [!abstract]- HOUSEKEEPING
> **`$= '[['+moment().format("YYYY-[W]ww")+'|Review this Week]]'`**
> **Project Review**
> ---
> **`$= '[['+moment().format("YYYY-MM")+'|Review this Month]]'`**
> **Season Review**
> **`$= '[['+moment().format("YYYY")+'|Review this Year]]'`**
> [!cite]- DATABASES
---
⭕ = Core System Database
🔴 = Workflow (aka Review Cycle Databases)
---
````
Currently this is effecting the query, dataview, and dataviewjs codeblocks and I am still quite unsure what could be the cause of this problem. It may be an issue on the obsidian API side that I did not understand, and I have reached out to them with no response (you can see in the other issue about the query codeblock).
Additionally, I am swamped and am having a hard time maintaining this plugin, so any PRs for this issue would be appreciated (or any ideas to solve the issue). My latest suspect may be the order in which obsidian prioritizes the codeblock languages, and I'll do some testing on that when I find the time.
Any news on this issue?