# seqnext

> Sequence library

Latest version **0.0.3** (published 2017-04-10) · MIT license · 0 weekly downloads

## Install

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

## Health

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

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

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.3 |
| Published | 2017-04-10 |
| First published | 2017-04-05 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | baavgai |
| Maintainers | baavgai |

## Links

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

## Recent versions

- 0.0.3 (latest) — 2017-04-10
- 0.0.2 — 2017-04-07
- 0.0.1 — 2017-04-05

## README

# seqnext - Sequences

A library of for "Sequences" in TypeScript / JavaScript.  

Written in TypeScript so you know the type definitions will always be valid and applicable.

## Sequences

The foundation of a Sequence in code:
```typescript
interface SeqNext<T> {
  (): [T, SeqNext<T>] | undefined;
}
```

You call a function, you get a value and another function poised to offer the next value.  
Or you get null, telling you there are no more values to be had.

This abstraction allows for a lazy model which is very useful when dealing with large amounts of data where you don't want all the values.
Or reading lines from a file.  Or rows from a database.  Or even reading an array.

Why would you want to use a Sequence for an Array?  The level of abstraction means you can test an array now, a database read later.  Also, there are a number of helpful tools for this Sequence.

This is inspired by Haskell's lazy paradigm and more concretely by [Microsoft F# Sequences](https://docs.microsoft.com/en-us/dotnet/articles/fsharp/language-reference/sequences).






## Test Code
Coming soon

## Licence
MIT

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