Skip to content

[Node.js] A function that remembers the values passed to it and returns true if a value is new.

License

Notifications You must be signed in to change notification settings

lamansky/is-new

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

is-new

A function that remembers the values passed to it and returns true if a value is new. Packaged as a Node.js module.

Installation

npm install is-new --save

Usage

const IsNew = require('is-new')

// Create instance
const isNew = IsNew()

// Works with objects
const obj = {}
isNew(obj) // true
isNew(obj) // false

// Works with scalars
isNew('test') // true
isNew('test') // false

About

[Node.js] A function that remembers the values passed to it and returns true if a value is new.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published