-
Notifications
You must be signed in to change notification settings - Fork 171
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
feat: Add unhighlightTag prop #99
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kaungmyatlwin Thanks for your contribution. I like the idea to have consistent highlight*
and unhighlight*
properties. Left a comment.
Hi @sergei-startsev , thanks for replying. I've added two test cases f8d34a1 for Please have a look. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kaungmyatlwin please exclude package-lock.json, yarn.lock from the PR.
@sergei-startsev Rebased against master. Can you check? |
@kaungmyatlwin your changes will be included into the next release. |
@sergei-startsev Hi there! Would you mind creating a new release with this change? Thanks! |
Description
This PR adds ability to render custom HTML tags / React Nodes instead of defaulting to
<span>
element.Problem
Defaulting to
<span>
is a good idea and must have, but sometimes we have edge cases where you need to pass custom React nodes in order to provide additional functionalities. Please see the Use Case below.Use Case
Should be able to render
<a>
tags whenever necessary or pass React components (such as<Linkify>
: https://github.com/tasti/react-linkify) to render the links properly.