Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
A second attempt at a little Jekyll plugin to parse ==text== into <mark>text</mark>
Jekyll::Hooks.register :pages, :pre_render do |page|
page.content = page.content.gsub(
/\=\=(.*)\=\=/i,
'<mark>\1</mark>'
)
end
@BorisAnthony

This comment has been minimized.

Copy link
Owner Author

@BorisAnthony BorisAnthony commented Jul 28, 2020

First attempt here:
https://gist.github.com/BorisAnthony/89a34ae67a84fd21e2717971482c6a9b

Oddly same problem: gsub does its thing, but any markdown contained in between does not get rendered as HTML afterwards (even though we are firing this "pre_render"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.