A simple web component to mark keywords in a string.
Install:
$ npm i -S keyword-mark-element
Include:
<script src="node_modules/keyword-mark-element/lib/keyword-mark.js"></script>Or in JavaScript:
import "./node_modules/keyword-mark-element/lib/keyword-mark.js";Use:
<keyword-mark keywords="foo">foo bar baz</keyword-mark>Essentially, any keywords specified in the keywords attribute will be
highlighted in the text content of the element.
MIT