Skip to content

An alternative to the sneaky ! negation operator for Javascript

License

Notifications You must be signed in to change notification settings

writetome51/javascript-not

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

not(booleanExpression): boolean

It's an alternative to writing !(booleanExpression).
not is just a little more noticeable than the sneaky ! negation operator.

Examples

not(false); // --> true

not(true); // --> false

not(1 === 2); // --> true

if ( not( isEmpty( [1,2,3,4] ) ) ) {
	console.log('The array contains items');
}
  // console: 'The array contains items'

Installation

npm i @writetome51/not

Loading

import { not } from '@writetome51/not';

About

An alternative to the sneaky ! negation operator for Javascript

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published