Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error using template #15

Open
RWOverdijk opened this issue Jul 2, 2014 · 3 comments
Open

Error using template #15

RWOverdijk opened this issue Jul 2, 2014 · 3 comments

Comments

@RWOverdijk
Copy link

I'm trying to set up jsdoc3 with jaguarjs, and it seems to not want to listen to me. At all.

I simply cloned https://github.com/davidshimjs/jaguarjs-jsdoc into the dir I'm working in, and created a config file in the same dir:

{
  "plugins": [ "plugins/markdown" ],
  "markdown": {
    "parser": "gfm"
  },
  "opts": {
    "template" : "jaguarjs-jsdoc",
    "recurse": true,
    "tutorials": "./tutorials",
    "destination": "./documentation"
  }
}

Then ran jsdoc: jsdoc -c jsdoc.json src/*

Just to get:

rwoverdijk@battlestation ~/projects/nodejs/islnew/tier3/assets/scripts/islive.io (master)
$ jsdoc -c jsdoc.json src/*

undefined:55
((__t=( filename ))==null?'':__t)+
        ^
ReferenceError: filename is not defined
    at eval (eval at <anonymous> (/usr/local/lib/node_modules/jsdoc/node_modules/underscore/underscore.js:1262:16), <anonymous>:55:9)
    at template (/usr/local/lib/node_modules/jsdoc/node_modules/underscore/underscore.js:1270:21)
    at exports.Template.partial (/usr/local/lib/node_modules/jsdoc/lib/jsdoc/template.js:62:29)
    at exports.Template.render (/usr/local/lib/node_modules/jsdoc/lib/jsdoc/template.js:81:24)
    at generateTutorial (/Users/rwoverdijk/projects/nodejs/islnew/tier3/assets/scripts/islive.io/jaguarjs-jsdoc/publish.js:501:25)
    at /Users/rwoverdijk/projects/nodejs/islnew/tier3/assets/scripts/islive.io/jaguarjs-jsdoc/publish.js:512:13
    at Array.forEach (native)
    at saveChildren (/Users/rwoverdijk/projects/nodejs/islnew/tier3/assets/scripts/islive.io/jaguarjs-jsdoc/publish.js:511:23)
    at Object.exports.publish (/Users/rwoverdijk/projects/nodejs/islnew/tier3/assets/scripts/islive.io/jaguarjs-jsdoc/publish.js:516:5)
    at Object.module.exports.cli.generateDocs (/usr/local/lib/node_modules/jsdoc/cli.js:412:18)

I'm using version:

rwoverdijk@battlestation ~/projects/nodejs/islnew/tier3/assets/scripts/islive.io (master)
$ jsdoc -v
JSDoc 3.3.0-alpha9 (Sat, 28 Jun 2014 15:26:03 GMT)

I also tried master, with no success.

@purtuga
Copy link

purtuga commented Jul 2, 2014

I also hit a problem (not the same error above) when running this against jsdoc v3.3.0ALPHA8... I tried it against jsdoc 3.2.2 and it worked...Maybe it will work for you as well..
I have been finding some issues with jsdoc v3.3.0, so I'm sticking to 3.2.2 for now. Sad that a npm install jsdoc defaults to the alpha versions...

@ouadi
Copy link

ouadi commented Oct 20, 2014

I have the same issue. And it is linked to the presence of tutorials. If you remove it from the config, things will works.

Is there a way to have some feedback from the developer of the template?

The layout of my test-project is:
project-home

|-- tut
|     |-- tut1.md
|     +--tut1.json
|-- jsdocconf.json
+-- Gruntfile.js

tut1.md

# Title 1
Text text text

tut1.json

{
    "title": "Tutorial 1"
}

jsdocconf.json

{
    "tags": {
        "allowUnknownTags" : true
    },
    "templates": {
        "cleverLinks": true,
        "monospaceLinks": true,
        "default": {
            "outputSourceFiles" : true
        },
        "applicationName": "SaphirJS",
        "disqus": "",
        "googleAnalytics": "",
        "linenums": false
    }
}

Gruntfile.js

        jsdoc: {
            all: {
                src: [
                    './src/main/js/**/*.js',
                ],
                options: {
                    destination: 'doc',
                    tutorials: './tut'
                    template : "node_modules/jaguarjs-jsdoc",
                    configure : "jsdocconf.json",
                },
            }
        },

@levithomason
Copy link

It doesn't appear this project is being maintained, however, there is a solution on SO for anyone looking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants