0.1.0 • Published 1 year ago

@byndyusoft-ui/highlighter v0.1.0

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

@byndyusoft-ui/highlighter

The Highlighter component is a React component designed to display and highlight text that matches a specified pattern. This component is flexible and allows for custom highlighting styles, making it useful for various text-emphasizing purposes such as search result highlighting or keyword emphasis.

Features

  • Pattern Matching: Highlights text matching a specified pattern.
  • Case Sensitivity: Supports both case-sensitive and case-insensitive matching.
  • Custom Highlighting: Allows the use of a custom function to define the highlighting style.
  • Optimized Rendering: Uses React's memoization (memo) to prevent unnecessary re-renders.

Installation

npm i @byndyusoft-ui/highlighter
# or
yarn add @byndyusoft-ui/highlighter

License

This project is licensed under the ISC License.