0.4.4 • Published 7 years ago

dejunk.js v0.4.4

Weekly downloads
3
License
AFL-2.0
Repository
github
Last release
7 years ago

A modified JS port of academia-edu/dejunk.

Detect keyboard mashing and other junk in your data.

var deJunk = require("dejunk.js")

isJunk('asd asd das as d'); // true


// if you need more info pass true as second parameter
var returnString = true;

deJunk.isJunk('asd asd das as d', returnString); // "asdf_row"

deJunk.isJunk('Hello', returnString); // false


deJunk.hasJunk('There once was a Moooooooooose with a big Kaboose @%@#**@(@)'); // false (20% junk)
deJunk.hasJunk('There aslkdjaslkdj was a Moooooose with a big Kaboose @%@#**@(@)'); // true (30%)

// or set the threshold yourself in the second param. Float representing % between 0 & 1
deJunk.hasJunk('There once was a Moooooooooose with a big Kaboose @%@#**@(@)', 0.1); // true (10% junk)

To do

  • memoize intensive functions
  • make whitelisting easier
  • improve docs
0.4.4

7 years ago

0.4.3

7 years ago

0.4.2

7 years ago

0.4.1

7 years ago

0.4.0

7 years ago

0.3.0

7 years ago

0.2.1

7 years ago

0.2.0

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago