*nix Programming Mammals

    marked-input

    0.1.1 • Public • Published

    Marked Input

    NPM Downloads

    Make your input box markable. Mark the unexpected text in your input box.

    Demo

    Installation

    npm i marked-input

    Usage

    <style>
    #input > em {
      background: yellow;
      font-style: normal;
    }
    </style> 
    <div id="input"></div>
    // Via NPM
    const markedInput = require('marked-input');
     
    // Via global, you'll get global variable `markedInput`
     
    markedInput.init({
      el: '#input',
      splitText: 10,  // text longer than 10 chars will be marked
      onChange: text => {
        console.log(`Significant text: ${text}`);
      },
    });

    Snapshots

    MarkedInput

    Keywords

    Install

    npm i marked-input

    DownloadsWeekly Downloads

    3

    Version

    0.1.1

    License

    MIT

    Last publish

    Collaborators

    • gera2ld