Bases: show the file's content as a property / column

What I’m trying to do

I am trying to create an overview of my daily notes. One note per row. First column is the file name, which is the date of creation.

In the second column, I would like to see the text in the file. Basically, the file’s content. Not just the file embeds or file links, but the full content. The same view as the hover preview would be perfect.

I understand the the point of Bases is to extract the properties, but this would be useful to me.

I would add that my daily notes are quite short such that this is a useful way to show case them.

Further this would allow me to filter through my “diary” of daily notes using tags such “#important_event” or the like.

Things I have tried

I have tried using functions from the Bases documentation to pull out the “file.content” or “file.text”, or something along those line, but I can’t figure out how to get this to work, if at all possible.

Am I missing the obvious here? Is there another much better way of doing this.

As far as possible I’d like to avoid using community plugins.

Thanks all in advance

6 Likes

Bases don’t/can’t read the file contents, only cached metadata about the note.

1 Like

I’d love to be able see the content of my notes in some way too. As a workaround, is it possible to get a preview of the link when you hover over it? This behavior is in Dataview and it lets me quickly get an overview of a note without having to click into it.

1 Like

Not sure if that would be useful for you, but try an approach using Dataview:

table file.lists.text
from #journal/daily 
sort desc
limit 100

Modify to your file structure. That should result in a table with file names (your dailies) and the text (note body) in the second column. It’s only a table, no fancy stuff from Bases.

I used a more complex version of this for weekly/monthly reviews, when I wanted a quick overview of what happened in the last period.

As an addendum to this request, I’d like to add a column that adds a short snippet from the note’s content. So something along the lines of note.content.slice( 0, 140)

I’m curious, is there a reason that notes’ content isn’t available?

2 Likes

Performance. Especially because the base is created with no filters by default with all notes shown as results.

Content search is okay if you apply some filters before.
I have a hunch Obsidian core Bases will not support it but once Bases API is out some 3rd party plugins will.

1 Like