Bill Keese | 21 May 2012 12:35
Favicon
Gravatar

module summaries

A lot of our modules have dueling summaries, ex:


define(["./_base/kernel", "./_base/lang", "./_base/array", "./_base/connect", "./query", "./ready"], function(dojo, lang, darray, connect, query, ready) {
// module:
// dojo/behavior
// summary:
// TODOC


dojo.behavior = new function(){
// summary:
// Utility for unobtrusive/progressive event binding, DOM traversal,
// and manipulation.
...

We should get rid of one or the other.    They essentially describe the same thing.

Any opinions on whether the summary should be at the module level (ie, the very top), vs. inside the returned object?

Perhaps occasionally it needs to be at the top, for modules returning strange values like strings or numbers or builtin methods:

define([], function(){
    // module:
    //       jsonparse
    // summary:
    //     function to parse json

    return JSON ? JSON.parse : function(){ ... };
});

_______________________________________________
dojo-contributors mailing list
dojo-contributors <at> mail.dojotoolkit.org
http://mail.dojotoolkit.org/mailman/listinfo/dojo-contributors

Gmane