-
-
Notifications
You must be signed in to change notification settings - Fork 382
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
Warn if "pipelines" are out of order. #47
Comments
That's a nasty gotcha. The MarkdownFilter documentation does specify it needs to be the first filter in the pipeline, but this information needs to be more discoverable. We can pass in the Pipeline instance into the context hash for filters to do more introspection. Would you be interested in creating a pull for that? |
One possibility would be to |
@envygeeks I wrote up some quick recommended changes for your example: https://gist.github.com/mtodd/216223f2307634e78e7b Let me know if you have any questions on normal usage. |
@mtodd Thanks for helping out! 🍻 |
I would love it if rather then sending a generic error that means nothing to the user (in some cases) and could be confusing, html-pipeline should detect order issues if there is a clear process order or
emoji
should convert theDocumentFragment
. What I mean is:Works, but
Fails. However your lib sends people a broad message that doesn't even hint closely to what the problem might be, it only sends: https://github.com/jch/html-pipeline/blob/master/lib/html/pipeline/text_filter.rb#L7 which can confuse some users who are simply doing the most simple things like:
This might be a problem with Emoji on Ruby 2.0.0-p0 though.
The text was updated successfully, but these errors were encountered: