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 🙏

© 2024 – Pkg Stats / Ryan Hefner

test-datasets

v1.0.8

Published

A collection of dataset JSON objects that can be used to different projects

Downloads

1,964

Readme

test-datasets

A collection of dataset that can be used to different projects and tests for random text generation.

npm version npm node-current

Installation

Make sure you have Node.js installed in your system. Open a Terminal/Command line window and type:

npm i test-datasets

Usage

Import the library into your code and use it as follows:

// import the datasets
import ds from 'test-datasets'
// or using node require
const ds = require('test-datasets')


// Generate a random name
ds.getRandomName()
// Generate 10 random names
ds.getRandomNames(10)

// Get a country name
ds.countries.getRandomCountry()

// Get a random Harry Potter character
ds.harrypotter.getRandomCharacter()
ds.harrypotter.getRandomName()

// Get a random Harry Potter spell
ds.spells.getRandomSpell()

// Get a random string from Regex
ds.randString.getRandomStringFromRegex('[a-z]{1,10}') // 'gsberhdykn', 'uquxlpmv', 'orxpzvfqe' etc
ds.randString.getRandomStringFromRegex('HELLO|WORLD') // 'HELLO' or 'WORLD'

// Get a random Game of Thrones character name
ds.got.getRandomName()

// Get a random Pokemon
ds.pokemon.getRandomPokemon()

// Generate a Lorem Ipsum string of given length
ds.lorem.generateLorem(30) // 'Velit aliqua eu officia fugia.'

// Get a name similar to what Docker generates
ds.dockername.getRandomDockerName() // 'Amazing Heisenberg'

// Get a random Marvel character
ds.marvel.getRandomName()

// Get a random character from Star Wars
ds.starWars.getRandomCharacter()

// Get a random character from The Big Bang Theory
ds.tbbt.getRandomName()

// Get some random celestial object or planet
ds.space.getRandomCelestialObject()
ds.space.getRandomPlanet()

// Get a random quote
ds.quotes.getRandomQuote()


// Available methods
const ds = {
    getRandomName: () => doMagic(),
    getRandomNames: () => doMagic(),
    countries: {
        getRandomCountry: () => doMagic(),
        getRandomCountries: () => doMagic()
    },
    dockername: {
        getRandomDockerName: () => doMagic(),
        getRandomDockerNames: () => doMagic(),
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic()
    },
    got: {
        getRandomCharacter: () => doMagic(),
        getRandomCharacters: () => doMagic(),
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic(),
        getRandomHouse: () => doMagic(),
        getRandomHouses: () => doMagic()
    },
    harrypotter: {
        getRandomCharacter: () => doMagic(),
        getRandomCharacters: () => doMagic(),
        getRandomHouse: () => doMagic(),
        getRandomHouses: () => doMagic(),
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic(),
        getRandomWand: () => doMagic(),
        getRandomWands: () => doMagic()
    },
    lorem: { generateLorem: () => doMagic() },
    marvel: {
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic()
    },
    pokemon: {
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic(),
        getRandomPokemon: () => doMagic(),
        getRandomPokemons: () => doMagic()
    },
    quotes: {
        getRandomQuote: () => doMagic(),
        getRandomQuotes: () => doMagic()
    },
    randString: {
        getRandomString: () => doMagic(),
        getRandomStringWithoutLength: () => doMagic(),
        getRandomStringFromRegex: () => doMagic()
    },
    space: {
        getRandomCelestialObject: () => doMagic(),
        getRandomCelestialObjectName: () => doMagic(),
        getRandomCelestialObjects: () => doMagic(),
        getRandomPlanet: () => doMagic(),
        getRandomPlanetName: () => doMagic(),
        getRandomPlanets: () => doMagic()
    },
    spells: {
        getRandomSpell: () => doMagic(),
        getRandomSpells: () => doMagic()
    },
    starWars: {
        getRandomCharacter: () => doMagic(),
        getRandomCharacters: () => doMagic(),
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic()
    },
    tbbt: {
        getRandomName: () => doMagic(),
        getRandomNames: () => doMagic()
    }
}

Contribute to this repo

Feel free to contribute any dataset to this repo by raising a PR :)

Contributors

Made with contributors-img.

Data Source

All these data are taken form data sources publicly available in the internet and I don't own any of it.

The datasets were collected and brought to one place as I love most of these shows/data and I like making them available as a utility that anyone can use.

All the rights belong to the corresponding data/franchise owner and if you have any issue with this being made available in this repo, request you to let me know and I will happily remove it.