A.) LOAD("a", "b", "c", function(...) { ... });
B.) LOAD(["a", "b", "c"], function(...) { ... });
Current show of hands. Please copy and update this block in responses.
A.)
B.) Kris Kowal +1, Christoph Dorn +1
Christoph Dorn on B: "This seems cleaner and easier to scan and lends
itself better to dynamic generation."
Kris Kowal
B.) +1 James Burke
Not adding the names, because I already started typing one message
before another came in with someone else's response in another thread,
so probably best to just indicate your preference and tabulate later.
James
A.)
B.) Kris Kowal, Christoph Dorn, Mikeal Rogers, James Burke
A.) Kevin H Smith
C) LOAD(<String,Array> ids, function(...) { ... });
A.) LOAD("a", "b", "c", function(...) { ... });
B.) LOAD(["a", "b", "c"], function(...) { ... });
C.) LOAD("a", function (a) { ... });
Hands:
A.) Kevin H Smith
B.) Kris Kowal, Christoph Dorn, Mikeal Rogers, James Burke
B+C.) Tom Robinson, Kris Kowal
--
You received this message because you are subscribed to the Google Groups "CommonJS" group.
To post to this group, send email to comm...@googlegroups.com.
To unsubscribe from this group, send email to commonjs+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/commonjs?hl=en.
Hands:
A.) Kevin H Smith
B.) Kris Kowal, Christoph Dorn, Mikeal Rogers, James Burke
B+C.) Tom Robinson, Kris Kowal, Irakli Gozalishvili, Hannes Wallnoefer
2011/1/27 Irakli Gozalishvili <rfo...@gmail.com>:
A.) LOAD("a", "b", "c", function(...) { ... });
B.) LOAD(["a", "b", "c"], function(...) { ... });
C.) LOAD("a", function (a) { ... });
Hands:
A.) Kevin H Smith
B.) Kris Kowal, Christoph Dorn, Mikeal Rogers, James Burke, John J Barton
B+C.) Tom Robinson, Kris Kowal, Irakli Gozalishvili, Hannes
Wallnoefer, Kevin H Smith
Update:
Hands:
Wallnoefer, Kevin H Smith, Christoph Dorn
I prefer that the API args look similar to any module declaration,
like the define/module.declare variants that allow specifying
dependencies as an array. I like the mental model of "dependencies are
always in an array", which allows for easier human reading of code,
and gives the complete module API (definition and dynamic require)
more consistency.
So I'm still in B).
James