-
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
10,057 additions
and
11,340 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
module.exports = { | ||
extends: ["eslint:recommended", "plugin:@typescript-eslint/recommended"], | ||
parser: "@typescript-eslint/parser", | ||
plugins: ["@typescript-eslint"], | ||
root: true, | ||
|
||
rules: { | ||
"@typescript-eslint/no-unused-vars": [ | ||
"warn", | ||
// Unused variables are fine if they start with an underscore | ||
{ args: "all", argsIgnorePattern: "^_.*", varsIgnorePattern: "^_.*" }, | ||
], | ||
}, | ||
|
||
overrides: [ | ||
{ | ||
files: ["test/**"], | ||
|
||
// Special config for test files | ||
rules: { | ||
"@typescript-eslint/no-non-null-assertion": "off", | ||
}, | ||
}, | ||
], | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,3 @@ | ||
{ | ||
"printWidth": 120, | ||
"tabWidth": 4, | ||
"singleQuote": true, | ||
|
||
"overrides": [ | ||
{ | ||
"files": "*.yml", | ||
"options": { "tabWidth": 2 } | ||
} | ||
] | ||
"printWidth": 120 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,33 @@ | ||
## v2.2.0 | ||
|
||
- Move to ESM by default | ||
- Drop support for node 12.x and 14.x | ||
(they probably still work, but they're EoL) | ||
|
||
## v2.1.2 | ||
|
||
- Improve tree-shakability when used in bundlers | ||
- Improve tree-shakability when used in bundlers | ||
|
||
## v2.1.1 | ||
|
||
- Improve documentation | ||
- Fix a bug in `reduce()` in a very small edge case | ||
- Improve documentation | ||
- Fix a bug in `reduce()` in a very small edge case | ||
|
||
## v2.1.0 | ||
|
||
The following functions retain richer type information about their arguments: | ||
|
||
- `ifilter()` | ||
- `filter()` | ||
- `partition()` | ||
- `ifilter()` | ||
- `filter()` | ||
- `partition()` | ||
|
||
For example, TypeScript will now know the following: | ||
|
||
```ts | ||
const items = [3, 'hi', -7, 'foo', 13]; | ||
const items = [3, "hi", -7, "foo", 13]; | ||
|
||
function isNum(value: unknown): value is number { | ||
return typeof value === 'number'; | ||
return typeof value === "number"; | ||
} | ||
|
||
const numbers: number[] = filter(items, isNum); // ✅ | ||
|
@@ -31,25 +37,25 @@ const [numbers, strings] = partition(items, isNum); // ✅ | |
// number[] | ||
``` | ||
|
||
- Add new `find(iterable, pred)` function, which is almost the same as | ||
`first(iterable, pred)` but behaves slightly more intuitive in the case | ||
where no predicate function is given. | ||
- Add new `find(iterable, pred)` function, which is almost the same as | ||
`first(iterable, pred)` but behaves slightly more intuitive in the case | ||
where no predicate function is given. | ||
|
||
- Fix bug in `chunked()` with `size=1` | ||
- Fix bug in `chunked()` with `size=1` | ||
|
||
## v2.0.0 | ||
|
||
**Breaking changes:** | ||
|
||
- Rewritten source code in TypeScript (instead of Flow) | ||
- Modern ESM and CJS dual exports (fully tree-shakable when using ESM) | ||
- Massively [reduced bundle size](https://bundlephobia.com/package/[email protected]) | ||
- Targeted ES2015 (instead of ES5) | ||
- Support only TypeScript versions >= 4.3 | ||
- Drop Flow support\* | ||
- Drop Node 10.x support | ||
- `icompact`, `compact`, and `compactObject` functions will now also remove | ||
`null` values, not only `undefined` | ||
- Rewritten source code in TypeScript (instead of Flow) | ||
- Modern ESM and CJS dual exports (fully tree-shakable when using ESM) | ||
- Massively [reduced bundle size](https://bundlephobia.com/package/[email protected]) | ||
- Targeted ES2015 (instead of ES5) | ||
- Support only TypeScript versions >= 4.3 | ||
- Drop Flow support\* | ||
- Drop Node 10.x support | ||
- `icompact`, `compact`, and `compactObject` functions will now also remove | ||
`null` values, not only `undefined` | ||
|
||
(\*: I'm still open to bundling Flow types within this package, but only if | ||
that can be supported in a maintenance-free way, for example by using a script | ||
|
@@ -58,97 +64,97 @@ add support for that, I'm open to pull requests! 🙏 ) | |
|
||
## v1.7.1 | ||
|
||
- Add missing re-export of `islice` at the top level | ||
- Add missing re-export of `islice` at the top level | ||
|
||
## v1.7.0 | ||
|
||
- TypeScript support! | ||
- Declare official support for Node 16.x | ||
- Drop support for Node 13.x (unstable release) | ||
- TypeScript support! | ||
- Declare official support for Node 16.x | ||
- Drop support for Node 13.x (unstable release) | ||
|
||
## v1.6.1 | ||
|
||
- Include an error code with every FlowFixMe suppression | ||
(Flow 0.132.x compatibility) | ||
- Include an error code with every FlowFixMe suppression | ||
(Flow 0.132.x compatibility) | ||
|
||
## v1.6.0 | ||
|
||
- New itertool: `heads()` | ||
- New itertool: `heads()` | ||
|
||
## v1.5.4 | ||
|
||
- Export `roundrobin()` at the top level | ||
- Export `roundrobin()` at the top level | ||
|
||
## v1.5.3 | ||
|
||
- Fix bug in `chunked()` when input is exactly dividable | ||
- Fix bug in `chunked()` when input is exactly dividable | ||
|
||
## v1.5.2 | ||
|
||
- Export `count()` function at the top level 🤦♂️ | ||
- Export `count()` function at the top level 🤦♂️ | ||
|
||
## v1.5.1 | ||
|
||
- Internal change to make the code Flow 0.105.x compatible. Basically stops | ||
using array spreads (`[...things]`) in favor of `Array.from()`. | ||
- Internal change to make the code Flow 0.105.x compatible. Basically stops | ||
using array spreads (`[...things]`) in favor of `Array.from()`. | ||
|
||
## v1.5.0 | ||
|
||
- Remove direct code dependency on `regenerator-runtime` (let `@babel/runtime` | ||
manage it) | ||
- Remove direct code dependency on `regenerator-runtime` (let `@babel/runtime` | ||
manage it) | ||
|
||
## v1.4.0 | ||
|
||
- Switch to Babel 7 | ||
- Switch to Babel 7 | ||
|
||
## v1.3.2 | ||
|
||
- Export `filter` at the top level | ||
- Export `filter` at the top level | ||
|
||
## v1.3.1 | ||
|
||
- New build system | ||
- Cleaner NPM package contents | ||
- New build system | ||
- Cleaner NPM package contents | ||
|
||
## v1.3.0 | ||
|
||
- Drop support for Node 7 | ||
- Drop support for Node 7 | ||
|
||
## v1.2.2 | ||
|
||
- Make itertools.js fully [Flow Strict](https://flow.org/en/docs/strict/) | ||
- Make itertools.js fully [Flow Strict](https://flow.org/en/docs/strict/) | ||
|
||
## v1.2.1 | ||
|
||
- Export `permutations()` at the top-level | ||
- Export `permutations()` at the top-level | ||
|
||
## v1.2.0 | ||
|
||
- Add port of `groupby()` function (see #87, thanks @sgenoud!) | ||
- Add port of `groupby()` function (see #87, thanks @sgenoud!) | ||
|
||
## v1.1.6 | ||
|
||
- declare library to be side effect free (to help optimize webpack v4 builds) | ||
- declare library to be side effect free (to help optimize webpack v4 builds) | ||
|
||
## v1.1.5 | ||
|
||
- Include regenerator runtime via babel-runtime | ||
- Include regenerator runtime via babel-runtime | ||
|
||
## v1.1.4 | ||
|
||
- Make `regenerator-runtime` a normal runtime dependency | ||
- Make `regenerator-runtime` a normal runtime dependency | ||
|
||
## v1.1.3 | ||
|
||
- Lower required version of `regenerator-runtime` | ||
- Lower required version of `regenerator-runtime` | ||
|
||
## v1.1.2 | ||
|
||
- Properly declare dependency on `regenerator-runtime` | ||
- Properly declare dependency on `regenerator-runtime` | ||
|
||
## v1.1.1 | ||
|
||
- Fix bug in `cycle()` with infinite inputs | ||
- Fix bug in `cycle()` with infinite inputs | ||
|
||
## v1.1.0 | ||
|
||
|
Oops, something went wrong.