GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
Part of #73.
Way late, but there it is! I think the createCallback docs need to be improved though, I couldn't think about a good use case for it...
Kinda-off-topic: I should be able to finish the when/callback stuff by tomorrow :)
Also run tests from the subdirectories
Don't force users to provide arguments
Remove the 'context' arg, as was done for 'function.js'
Add tests for node_fn.apply
docs for node_fn.apply
Add tests for node_fn.call
That are not really different from the ones for 'node_fn.apply'... Is
that a problem?
Docs for node_fn.call
Add tests for node_fn.bind
Add docs for node_fn.bind
The promiseRead example fits node_fn.bind better
Implement tests and doc for createCallback
Awesome, can't wait to dig into this tomorrow :) thanks!
Hmm, very minor: people might tend to call the node/function module variable whatever they see us calling it. Since the cujojs naming scheme tends to use camel case rather than underscores, how about we use something without an underscore?
How about nodefn ... just nix the underscore :)
I wonder if people would find 'nodeback' or 'createNodeback' to be a more intuitive name than 'createCallback'. I don't mind 'createCallback', but just want to see if you have any thoughts.
Overall, this looks great, once again. Have a look at the very minor comments, and then I think we can get this merged.
Do you have any particular use case for createCallback that isn't covered by bind? Maybe it will throw some light at whether it is a good name or not :)
Argh, github didn't notify me about your node_fn -> nodefn update! Sorry about that! I'll look it over asap.
Heh, honestly, I can't really think of any good use cases for createCallback. Maybe after its in the wild, people will discover some ... of course, that means it'll be harder to change the name. Oh well, in the absence of any real motivation or evidence for changing it, let's just go with it as is :)
Merge pull request #90 from riccieri/node
Document and test when/node/function