# markup_highlight

> Add markup highlight to the results in web based search interface

Latest version **1.3.7** (published 2020-04-04) · ISC license · 0 weekly downloads

## Install

```sh
npm install markup_highlight
pnpm add markup_highlight
yarn add markup_highlight
bun add markup_highlight
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.3.7 |
| Published | 2020-04-04 |
| First published | 2020-04-03 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 13.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Abhinav Nath Gupta |
| Maintainers | abhiit89 |
| Keywords | search highlight, markup highlight |

## Links

- npm: https://www.npmjs.com/package/markup_highlight
- Repository: https://bitbucket.org/abhinavstyquo1989/markup_highlight
- Homepage: https://bitbucket.org/abhinavstyquo1989/markup_highlight#readme
- npm.io page: https://npm.io/package/markup_highlight

## Alternatives

- [@oh-my-pi/pi-natives](https://npm.io/package/@oh-my-pi/pi-natives.md) — 51.8K weekly downloads
- [@capgo/capacitor-light-sensor](https://npm.io/package/@capgo/capacitor-light-sensor.md) — 3.0K weekly downloads
- [@heyhuynhgiabuu/pi-diff](https://npm.io/package/@heyhuynhgiabuu/pi-diff.md) — 492 weekly downloads
- [@lotsa/verdant-lang-asm](https://npm.io/package/@lotsa/verdant-lang-asm.md) — 38 weekly downloads
- [new-era-syntax](https://npm.io/package/new-era-syntax.md) — 20 weekly downloads

## Recent versions

- 1.3.7 (latest) — 2020-04-04
- 1.3.5 — 2020-04-04
- 1.3.4 — 2020-04-04
- 1.3.3 — 2020-04-04
- 1.3.2 — 2020-04-04
- 1.3.0 — 2020-04-04
- 1.2.0 — 2020-04-03

## README

# Markup Highlight

[![install size](https://packagephobia.now.sh/badge?p=env-explorer)](https://packagephobia.now.sh/result?p=markup_highlight)

## Introduction

Markup Highlight is a library, which will process a string or a set of strings against a search key and modify the input string by highlighting the matched part from the input strings.

---

## Steps to use

1. Install the dependency.

   `npm i markup_highlight`

2. Import the `MarkupHighLight` class in your module or component, as shown in code snippet below,

   ```typescript
   import { MarkupHighLight } from 'markup-highlight';
   ```

3. Invoke the constructor `MarkupHighLight(searchText, searchKey)` to set the intial properties.

   ```typescript
   const markupObject = new MarkupHighLight(searchText, searchKey);
   ```

4. After setting the values in constructor, invoke `getHighLightedText()` method to get the highlighted.
   ```typescript
   const result = markupObject.getHighLightedText();
   ```

---

## Examples

1. For usage in `Typescript`, please refer
   [here](https://stackblitz.com/edit/typescript-3497xu?file=index.ts).

2. For Usage in `Angular` application, please refer [here](https://stackblitz.com/edit/angular-14wopb).

---

---
_Source: https://npm.io/package/markup_highlight · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
