
Security News
/Research
Popular node-ipc npm Package Infected with Credential Stealer
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
targetprocess-jsdoc-gen
Advanced tools
This tool is a simple node.js console utility based on awesome [jsdoc2md](https://github.com/jsdoc2md) for generating markdown files per module based on JsDoc documentation. Each module is split to a separate markdown file, and an additional index file is
This tool is a simple node.js console utility based on awesome jsdoc2md for generating markdown files per module based on JsDoc documentation. Each module is split to a separate markdown file, and an additional index file is generated with list of all found modules.
Additionaly, the generator makes some heuristic assumptions about parsed JsDoc:
@module. Global JsDoc annotations (i.e. JsDoc in files without @module declaration) are ignored@properties, @params and @returns type specifications (i.e. @class, @typedef and @callback annotations) are assumed to belong to current module, if they appear within it. As a result, there is no need to use fully-qualified names for module-scoped typedefs (resolves https://github.com/jsdoc3/jsdoc/issues/969)export class definitions (https://github.com/jsdoc3/jsdoc/issues/1137)Basic usage:
> targetprocess-jsdoc-gen -i <input file pattern> -o <output directory>
Command line arguments:
| Argument | Description |
|---|---|
-i,--input | Input file or file glob pattern. Typically wildcard pattern can be used, i.e. tau/scripts/tau/api/**/*.js |
-o,--output | Output directory path |
--index | Index file name, defaults to index.md. |
--title | Title generated for index file, defaults to Targetprocess API documentation |
--footnote | An optional footnote that will be inserted at the end of index file |
Output will generate a folder structure based on module names, so if, for example, input files define @module my/module, output will contains index.md file and module.md file in my subdir.
All links in index are relative, so output can be stored in source control as is.
A common usage scenario is using generator as a pre-commit hook.
@module declaration in files. Documentation for globals is not generated by default.tau/api/acid/v1, that should be the module name.@typicalname to make module member names a bit more friendly to read. I.e. module may be named underscore, but for clarity in documentation, its @typicalname can be set to _.camelCase and slash/separated/namespaces for module names. Avoid dots and dashes.@typedef for complex objects in parameters and return values.@class and @memberOf tags to describe literal object as class.@callback to document callback functions. Make callback a part of class if callback is used only inside that classExample:
/**
* Some client side API version 1.
* @module tau/api/clientSideApi/v1
* @typicalname clientSideApi
*/
/**
* Some callback.
* @callback someMethodCallback
* @param {string} callbackParam - param
*/
/**
* Some class.
*/
export class MyClass {
/**
* Creates a new MyClass instance based on number
* @param {number} x - some input number
*/
constructor(x) {
}
/**
* Registers some callback
* @param {someMethodCallback} callback - callback parameter
*/
someMethod(callback) {
}
/**
* Some static method of MyClass
*/
static someStaticMethod() {
}
}
/**
* Some very complex type
* @typedef ComplexType
* @param {string} someParam - some parameter
* @param {number} otherParam - other parameter
*/
/**
* @function
* @param {MyClass} myClassInstance - some description
* @returns {ComplexType} - description of returned value
*/
export function someFunction(myClassInstance) {}
The above example produces the following output for module tau/api/clientSideApi/v1:
Some client side API version 1.
functionSome class.
Kind: static class of tau/api/clientSideApi/v1
Creates a new MyClass instance based on number
| Param | Type | Description |
|---|---|---|
| x | number | some input number |
Registers some callback
Kind: instance method of MyClass
| Param | Type | Description |
|---|---|---|
| callback | someMethodCallback | callback parameter |
Some static method of MyClass
Kind: static method of MyClass
ComplexTypeKind: static method of tau/api/clientSideApi/v1
Returns: ComplexType - - description of returned value
| Param | Type | Description |
|---|---|---|
| myClassInstance | MyClass | some description |
functionSome callback.
Kind: inner typedef of tau/api/clientSideApi/v1
| Param | Type | Description |
|---|---|---|
| callbackParam | string | param |
Some very complex type
Kind: inner typedef of tau/api/clientSideApi/v1
| Param | Type | Description |
|---|---|---|
| someParam | string | some parameter |
| otherParam | number | other parameter |
FAQs
This tool is a simple node.js console utility based on awesome [jsdoc2md](https://github.com/jsdoc2md) for generating markdown files per module based on JsDoc documentation. Each module is split to a separate markdown file, and an additional index file is
The npm package targetprocess-jsdoc-gen receives a total of 12 weekly downloads. As such, targetprocess-jsdoc-gen popularity was classified as not popular.
We found that targetprocess-jsdoc-gen demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.