npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

is-gibberish

v0.1.0

Published

Tells you if a string is nonsense

Readme

Is Gibberish

This package finds out if a string is real language or just nonsense. it returns a boolean, and you can tweak its sensitivity or exclude certain words.

What is it good for?

It might be good for:

  • Checking which files have human readable names.
  • Checking if a string is good to be used as a title for an entry.
  • Comparing two dodgy strings and seeing which is better.

Examples

Simple example:

const isGibberish = require('is-gibberish')

console.log(isGibberish('Hello there!'))
// false

console.log(isGibberish('asfafasfasfafg'))
// true

Here's a more advanced example that finds filenames that make no sense:

const isGibberish = require('is-gibberish')
// Get your data, this can be anything, in this case it happens to be a large
//array filenames.
const filenames = require('./filenames')

const OPTIONS = {
  // These are totally English, silly robot.
  exclude: ['hmmmmmmmmmm', 'javascript-02', 'lolnoob'],
  // Play with this value to see changes in the returned array.
  sensitivity: 0.111
}

const badFilenames = filenames
  .map(filename => (isGibberish(filename, OPTIONS) ? filename : undefined))
  .filter(Boolean)

console.log(JSON.stringify(badFilenames, null, 2))
console.log(
  `There is a total of ${filenames.length} filenames
of which ${badFilenames.length} is gibberish`
)

You can find the above example from the examples dir of this repo. If you want to play with it, just clone this repo and run npm run example.

By default it returns a boolean, but it can be configured to return the score, also, if some more advanced comparing is needed:

const isGibberish = require('is-gibberish')

const OPTIONS = { returnScore: true }
const string1 = isGibberish('lolnoob', OPTIONS)
const string2 = isGibberish('lolwut', OPTIONS)

console.log('`string1` makes this much sense:', string1)
console.log('and `string2` this much:', string2)

API

isGibberish(input[, options])

Returns: boolean|number

input

Type: string

options.exclude

Type: array

Exclude from analysis and always return false. These are the exceptions that you know are not real words, but you’d still like to classify as real words.

options.sensitivity

Type: number Default: 0.111

How sensitive the match is. Lower the number, the more forgiving it is. Through quasi experimental research done in my research laboratory, I'd say 0.111 is good value to start with.

How does it work?

This is just a thin convenience wrapper around languagedetect package.