You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

fn-code

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fn-code - npm Package Compare versions

Comparing version

to
0.0.2

2

package.json
{
"name": "fn-code",
"version": "0.0.1",
"version": "0.0.2",
"description": "Functions (fn) to make code cleaner",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -23,6 +23,3 @@ # Fn functions

```typescript
// Typescript
import fn from 'fn-code'
// Commonjs
const fn = require('fn-code')
```

@@ -71,3 +68,3 @@

Ughhh! This escalates badly. Also ternary operator is only clean if the third operand is default value (not another conditional).
Ughhh! This escalates badly. Also, the ternary operator is only clean when the third operand is the default value (and not another conditional).

@@ -92,4 +89,2 @@ So, you are clever and you make a function:

Alternatively, if it feels more familiar you can use `fn.switch` as it is an alias for `fn.one`,.
## Usage

@@ -111,3 +106,4 @@

What if you want to have a default value for binomialName when no condition is met? For that, you can use the third optional argument, passing `{ default: '' }`
But what if you want to have a **default** value for binomialName when no condition is met?
For that, you can use the third optional argument, passing `{ default: '' }`

@@ -124,2 +120,4 @@ ````typescript

Alternatively, if it feels more familiar you can use `fn.switch` instead, as it is an alias for `fn.one`.****
## Testing

@@ -126,0 +124,0 @@

Sorry, the diff of this file is not supported yet