Answer the question
In order to leave comments, you need to log in
What is the correct way to write jsdoc (require.js + backbone)?
Hello.
I will go straight to the question, bypassing the water.
There is a set of modules/classes of the following form:
Parent
define([
"backbone", "lodash", "jquery"
], function (
Backbone, _, $
){
return Backbone.View.extend({...})
}
define([
"parentClass"
], function (
parentClass
){
return parentClass.extend({...})
}
Answer the question
In order to leave comments, you need to log in
I would do this:
Parent
define([
'backbone',
'lodash',
'jquery',
], function (
Backbone,
_,
$
) {
/**
* @classdesc Best Parent class ever
* @class
*/
var Parent = Backbone.View.extend({
...
});
return Parent;
});
define([
'Parent',
], function (
Parent
) {
/**
* @classdesc Little children
* @class
* @augments Parent
*/
var Child = Parent.extend({
...
});
return Child;
});
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question