Highlight A Keyword In A Piece Of Text

A React component that highlights a keyword in a piece of text and returns a React element.

How to use it:

1. Install & import.

# NPM
$ npm i react-keywords
import React from 'react';
import Keywords from 'react-keywords';

2. Basic usage.

export default function Demo() {
  return (
    <Keywords value="react">
      Your Text Here
    </Keywords>
  );
}

Preview:

Highlight A Keyword In A Piece Of Text

Download Details:

Author: uiwjs

Live Demo: View The Demo

Download Link: Download The Source Code

Official Website: https://github.com/uiwjs/react-keywords

License: MIT

You Might Be Interested In:

Add Comment