0

I'm running JSDuck v5.3.4 on Solaris, with a single, very simple input file:

/**
 * @class Designer
 */

And I run it like this:

~/.gem/ruby/1.9.1/bin/jsduck --out ~/public_html/duck   foo.js

When I try to browse to the generated content, I see the big loading gear and the green JSDuck banner, but it never finishes. On the Chrome inspector console I see a JS error:

Uncaught TypeError: undefined is not a function app-0c945a27f43452df695771ddb60b3d14.js:1
Ext.define.setLogic app-0c945a27f43452df695771ddb60b3d14.js:1
Ext.define.initComponent app-0c945a27f43452df695771ddb60b3d14.js:1
Ext.define.constructor ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.constructor ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.constructor ext-all.js:38
i ext-all.js:38
Ext.apply.widget ext-all.js:38
Ext.define.create ext-all.js:38
Ext.define.lookupComponent ext-all.js:38
Ext.define.prepareItems ext-all.js:38
Ext.define.add ext-all.js:38
Ext.define.initItems ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.initItems ext-all.js:38
Ext.define.initComponent ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.initComponent ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.initComponent ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.initComponent app-0c945a27f43452df695771ddb60b3d14.js:1
Ext.define.constructor ext-all.js:38
b.implement.callParent ext-all.js:38
Ext.define.constructor ext-all.js:38
(rest of the stack just repeats the recursive call chain)

I can generate this doc just fine on Windows using the stand-alone Win32 JSDuck executable (also v5.3.4)

I would appreciate any help in figuring out what I might be doing wrong! There are are no source maps in the generated output, nor can I find any way to disable the minification or source maps for the bundled version of Ext4. Goolging for this "Uncaught TypeError: ..." is not fruitful, given that this is the most common JS error.

Armentage
  • 12,065
  • 8
  • 33
  • 33

1 Answers1

0

Looks like it fails inside the setLogic method of Docs.view.cls.Tree, when trying to initialize the left-hand side class tree.

Maybe there's something wrong with the data that is passed to the web app. JSDuck generates a data-SOMEHASH.js file to its output directory. Looking at this could provide some hindsight.

PS. use the --pretty-json option for more readable data.js output.

Rene Saarsoo
  • 13,580
  • 8
  • 57
  • 85