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

Allow filters to generate content for other filters #55

ddfreyne opened this issue Nov 17, 2019 · 1 comment

Allow filters to generate content for other filters #55

ddfreyne opened this issue Nov 17, 2019 · 1 comment


Copy link

@ddfreyne ddfreyne commented Nov 17, 2019

Currently, filters only generate one kind of output.

It would be useful to let filters also generate other kinds of output. For example:

  • a Markdown filter could output HTML, but also a parsed representation. Another filter could then do something with that parsed representation, which would be faster (as it eliminates another parsing step).

  • A Sass filter could generate CSS but also all the information needed to efficiently generate a sourcemap.

Ideally, the non-primary output content would be lazily-generated, i.e. only generated when another filter actually uses the data.


This comment has been minimized.

Copy link

@gpakosz gpakosz commented Nov 23, 2019

Well... filters being able to generate content for other filters...

I don't how what it means with respect to reps and the ability to write different snapshots to different files.

At least, what would be useful is to have a way to let filter pin some additional data to an item: for example a :mathjax filter would be able to "mark" an item with "hey I've found some LaTeX in there!" and later during the layout phase you can know "oh some LaTeX got found, let's link to the MathJaX css stylesheet"

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