tagterm

0.0.3 • Public • Published

tagTerm

Encapsulates a term within a string with html tags of your choosing.

Install

$ npm install tagterm

Usage

tagterm(input, term, tag)

In JS

var tagterm = require('tagterm');
input = "hello world, how are you?";
input = tagterm(input, "world", "em");

Output

hello <em>world</em>, how are you?

As HTML

hello world, how are you?

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i tagterm

      Weekly Downloads

      2

      Version

      0.0.3

      License

      WTFPL

      Last publish

      Collaborators

      • dual1ty