Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Inline Fields on a Per-Note Basis #51

Open
iamrecursion opened this issue Jul 4, 2024 · 7 comments
Open

[Feature Request] Inline Fields on a Per-Note Basis #51

iamrecursion opened this issue Jul 4, 2024 · 7 comments

Comments

@iamrecursion
Copy link

Currently we have the ability to enable/disable inline fields globally. Many notes I never care about having indexed for inline fields, but some I absolutely do.

To that end, I was wondering if any thought has been given to allowing notes to opt-in selectively using a key in the (always indexed) frontmatter. Something like datacoreParseInlineFields: true or similar.

@blacksmithgu
Copy link
Owner

blacksmithgu commented Jul 4, 2024

I'm curious if you want this because of inline fields causing you notable performance problems, or just as a cleanliness thing. If it's purely performance than there is some other stuff I can improve to make this less annoying.

@iamrecursion
Copy link
Author

A bit of both, but primarily performance. My vault is ~12k notes and so takes a noticeable amount of time to index. On mobile it takes a significant amount of memory that will sometimes crash the app.

@blacksmithgu
Copy link
Owner

There is a flag that disables all inline fields - if you disable dataview (so only datacore enabled) with that flag, is indexing much faster? (It would not surprise me, given skipping inline fields allows skipping a LOT of parsing logic).

Is a frontmatter entry the right level of abstraction here? Would a tag be better? Or something in the "settings" menu that you can have a list of files for?

@cdloh
Copy link

cdloh commented Jul 6, 2024

IMO a frontmatter field is the best. Using tags for things over then tagging notes always feels like overloading the field to me. Having a specific field designed just for this sounds like the biggest win to me.

I also prefer it over a field in settings because then I can just add notes for indexing as I create them rather then having to go into the settings every time.

@iamrecursion
Copy link
Author

Yeah it's noticeably faster to index if I disable that toggle in settings!

I would also think that frontmatter is the best solution. It's something I feel like I would want to decide on the fly, rather than something I can easily determine up front.

@blacksmithgu
Copy link
Owner

My stance on this - for performance problems I'd like to just try and make general performance better than offering too many precise levers for manipulating performance, since having to explicitly remember to set this on pages seems like pretty annoying user experience. I'm going to try improving some of the import logic to make the performance here generally better, but if it doesn't work, I'll add some sort of option for conditional parsing of inline fields.

@iamrecursion
Copy link
Author

Okay, sounds like a plan!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants