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

Change ordering of node.getNext() and context.render(node) in CoreHtmlRenderer.java #365

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

silentbaws
Copy link

Getting the next node before rendering the current one prevents a renderer from contextually unlinking the next node.

@robinst
Copy link
Collaborator

robinst commented Mar 23, 2025

Hmm, not sure how I feel about unlinking nodes during rendering. Can you explain how you're marking use of this? I'm wondering if it would be better to do this in a preprocessor step (e.g. could replace both nodes with a custom one).

@silentbaws
Copy link
Author

Hmm, not sure how I feel about unlinking nodes during rendering. Can you explain how you're marking use of this? I'm wondering if it would be better to do this in a preprocessor step (e.g. could replace both nodes with a custom one).

On mobile so can’t do a full write up of what I’m running in to but the gist is. I’m trying to render obsidian links/images.

I have a custom link processor for that here but this has a side effect of creating nodes that I have to collapse hackily during rendering here.

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

Successfully merging this pull request may close these issues.

2 participants