Skip to content

Commit

Permalink
FIX: Placeholder curry
Browse files Browse the repository at this point in the history
  • Loading branch information
Łukasz A.J. Wrona committed May 30, 2016
1 parent d7338e6 commit 0a7f0ab
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.js
Expand Up @@ -162,7 +162,7 @@ module.exports = {
"no-trailing-spaces": "error",
"no-undef-init": "off",
"no-undefined": "off",
"no-underscore-dangle": "error",
"no-underscore-dangle": "off",
"no-unmodified-loop-condition": "error",
"no-unneeded-ternary": "error",
"no-unused-expressions": "error",
Expand Down
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -707,7 +707,7 @@ F.F = function () {
}
}

F._ = R._
F._ = R.__

F.resolver = x => () => x
F.rejector = x => () => {
Expand Down
5 changes: 5 additions & 0 deletions test/main.js
Expand Up @@ -146,6 +146,11 @@ describe("curry", () => {
.end(done)
})

it("curry with placeholders", () => {
const push = F.curry((obj, arr) => [ ...arr, obj ])
const pushInto = push(F._, [ 1, 2, 3 ])
assert.deepEqual(pushInto(4), [ 1, 2, 3, 4 ])
})
})

describe("range", () => {
Expand Down

0 comments on commit 0a7f0ab

Please sign in to comment.