otris / jsdoc-tsd

JSDoc template for generating TypeScript definition files based on JSDoc comments.
MIT License
29 stars 7 forks source link

Template can't be used with grunt #1

Closed wehrstedt closed 6 years ago

wehrstedt commented 6 years ago

If you try to use this template with grunt, you will get the following error:

Running "jsdoc:typings" (jsdoc) task
>> FATAL: Unable to load template: Cannot find module 'E:\<project>\node_modules\jsdoc-tsd/publish'
Warning: jsdoc terminated with a non-zero exit code Use --force to continue.

Aborted due to warnings.

Version: v0.1.0 Grunt-Config:

jsdoc: {
    typings: {
        src: "src",
            options: {
                destination: "dist/typings",
                recurse: true,
                template: "node_modules/jsdoc-tsd"
            }
        }
    }
}
nkochakian commented 6 years ago

I get this error when I try to run it in any situation. I don't think this is a grunt specific problem.

wehrstedt commented 6 years ago

Can you tell me how exactly you use this plugin? If I call jsdoc -t node_modules/@otris/jsdoc-tsd/src-out/core -r <path to your source files>

it works fine for me

nkochakian commented 6 years ago

The documentation says to use node_modules/@otris/jsdoc-tsd as the template argument, which is how I would have expected it to work. It might make sense to do something similar to https://github.com/englercj/tsd-jsdoc/issues/18 for publishing.

wehrstedt commented 6 years ago

yap, sorry. This should normaly work, but there is some problem in the configuration of the module. But it's actually the same problem. But I will try to fix that!

wehrstedt commented 6 years ago

@nkochakian Published a new version. Please update your local module and try again