# ski

> eponymous functions from the SKI calculus

Latest version **2.0.0** (published 2015-12-02) · CC-0 license · 0 weekly downloads

## Install

```sh
npm install ski
pnpm add ski
yarn add ski
bun add ski
```

## Health

**Score 23/100 (F)** — status: abandoned.

Positive: has types package; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2015-12-02 |
| First published | 2013-02-08 |
| Weekly downloads | 0 |
| License | CC-0 |
| TypeScript types | separate (@types/ski) |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | jden |
| Maintainers | jden |
| Keywords | identity, constant, SKI, combinator |

## Links

- npm: https://www.npmjs.com/package/ski
- Repository: https://github.com/jden/ski
- Homepage: https://github.com/jden/ski#readme
- Issues: https://github.com/jden/ski/issues
- npm.io page: https://npm.io/package/ski

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 2.0.0 (latest) — 2015-12-02
- 1.0.0 — 2013-02-08

## README

# ski
eponymous functions from the SKI calculus

## installation

    $ npm install ski

## usage

    var ski = require(ski)
    var S = ski.S
    var K = ski.K
    var I = ski.I

    var log = console.log.bind(console)

    var tenner = S(K, log, 10)
    // 10 logged to console
    // tenner === 10

    var truth = ski.K(true)
    truth()
    // => true

    ski.I(5)
    // => 5

The module is also split into files, so you can use commonjs path syntax to only load the function(s) you need:

    var S = require('ski/s')
    var K = require('ski/k')
    var I = require('ski/i')

## api

descriptions adapted from wikipedia:

### `I = function (x)`, the identify function

I returns its argument:

    I(x) => x


### `K = function (x)`, the constant function

K, when applied to any argument x, yields a one-argument constant function Kx , which, when applied to any argument, returns x:

    K(x) => (y) => x

### `S = function (x, y, z)`, the substitution function

S is a substitution operator. It takes three arguments and then returns the first argument applied to the third, which is then applied to the result of the second argument applied to the third. More clearly:

    S(x, y, z) === x(z)(y(z))

## license
[CC 0](http://creativecommons.org/publicdomain/zero/1.0/) (public domain)

---
_Source: https://npm.io/package/ski · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
