Skip to content
Snippets Groups Projects

Add handle_href option for href pre-processing

Merged Justin Tormey requested to merge jtormey/linkify:handle-href into master

The implementation of this is different from mention_handler and hashtag_handler, because the intent is to just process the href, not to have full control over generating the anchor element itself.

This makes it easy to use with Phoenix router helpers, specifically for generating exit links (as mentioned in the original issue). Example:

Linkify.link my_text, href_handler: &Routes.exit_link_path(MyApp.Endpoint, :redirect, to: &1)

Closes #19 (closed)

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading