0.0.0 • Published 1 year ago

negate-ts v0.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

banner

Negate-ts is a TypeScript library that provides a simple and intuitive way to perform logical negation of boolean values. It is designed to be flexible and reliable, and can be used in a variety of contexts.

Installation

npm install negate-ts

Usage

import { not } from 'negate-ts';

not(true); // false
not(false); // true

Why?

Read this beautiful code:

if(not(havePermission)) {
  // do something
}

You can say "not" to your code, and it will be more readable. Try this:

if(!havePermission) {
  // do something
}

It's not the same, right? How you can say "!" to your code? You can't. You can only say "not".

License

Released under the MIT License.

Copyright (c) 2023 Thiago da Silva Teixeira