8000 Wrong example in Document for curry function · Issue #5911 · lodash/lodash · GitHub
[go: up one dir, main page]

Skip to content

Wrong example in Document for curry function #5911

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prd-quy-nguyen opened this issue Jul 31, 2024 · 0 comments
Open

Wrong example in Document for curry function #5911

prd-quy-nguyen opened this issue Jul 31, 2024 · 0 comments

Comments

@prd-quy-nguyen
Copy link
prd-quy-nguyen commented Jul 31, 2024

https://lodash.com/docs/4.17.15#curry

var abc = function(a, b, c) {
  return [a, b, c];
};
 
var curried = _.curry(abc);
 
curried(1)(2)(3);
// => [1, 2, 3]
 
curried(1, 2)(3);
// => [1, 2, 3]
 
curried(1, 2, 3);
// => [1, 2, 3]
 
// Curried with placeholders.
curried(1)(_, 3)(2);
// => [1, 3, 2]

The last example is incorrect

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant
0