
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
Unopinionated, simple and powerful documentation generator.
$ npm i -g javadoc
This project was created to simplify the documentation of any code that accepts this kind of comments:
/**
*
* Some description here. It accepts (optional) **markdown typing**.
*
* @some-property Some value in *markdown*
* @some-property Some value in *markdown*
* @some-other-property Some value in *markdown*
* @some-more-properties Some value in *markdown*
* The continuation of the value.
* It can take as much lines as you need.
* @and-more-properties
* @and-more
* @and-more...
*
*/
These are some of the advantages of this tool compared to other tools:
As simple as:
$ javadoc
--include "**/*.js" "**/*.ts"
--exclude "**/node_modules/**" "**ignore**"
--format markdown
--output README.md
Or abbreviatedly:
$ javadoc
-i "**/*.php" "**/*.sql"
-e "**/node_modules/**" "**ignore**"
-f json
-o README.md
Type javadoc --help to see the help.
require("javadoc").generate({
include: ["**/*.js", "**/*.ts"],
exclude: ["**/node_modules/**"],
format: "markdown",
output: "README.md"
}).then(report => {
// manage a report of success and errors...
}).catch(error => {
// manage the error...
});
Here you will find the whole API available for programmatic usage, documented.
Note: the main interesting method is Javadoc.generate, which is the one called by the CLI.
JavadocType: Class. Function.
Description: Master class of the javadoc package.
Javadoc.REGEX_PATTERNSType: Static property. Object.
Description: Regular expression patterns used by the class.
Javadoc.DEFAULT_GLOB_OPTIONSType: Static property. Object.
Property:
cwd. Defaults to process.cwd(). Allowed options at glob package
dot. Defaults to true. Allowed options at glob package
Description: Default options used by the glob package.
Javadoc.DEFAULT_OPTIONSType: Static property. Object.
Property:
include:Array<String>. Defaults to ["**/*.js"]. Allowed rules at glob package.
exclude:Array<String>. Defaults to ["**/node_modules/**.js"]. Allowed rules at glob package.
format:String. Defaults to "markdown". Allowed values:
"md""json"output:String. Defaults to undefined. File into which dump the results. Required value.
Description: General options of the Javadoc.generate main method.
Javadoc.findFilesType: Static method. Function.
Parameter:
parameterIncludes:Array<String>. Replaces DEFAULT_OPTIONS.include as value.
parameterExcludes:Array<String>. Replaces DEFAULT_OPTIONS.exclude as value.
parameterOptions:Object. Overrides DEFAULT_GLOB_OPTIONS as object.
Returns: files:Promise<Array>. Asynchronously, returns an array of matched files (as Strings).
Description: Finds files based on glob patterns (more info) included, excluded and glob options (more info).
Javadoc.findCommentsInFileType: Static method. Function.
Parameter: file:String. File into which look for the javadoc-comments.
Returns: matches:Promise<Array<Object>>. Asynchronously, returns a list of matched javadoc-comments (as Objects) found in the passed file.
Description: From a file, it returns (asynchronously, by a Promise) javadoc-comments represented as Objects.
Javadoc.findCommentsInStringType: Static method. Function.
Parameter: text:String. Text into which look for the javadoc-comments.
Returns: totalMatches:Array<Object>. List of javadoc-comments (as Objects) found in the passed String.
Description: Finds javadoc-comments (as Objects) from a String.
Javadoc.formatJsonToMarkdownType: Static method. Function.
Parameter: fileComments:Array<Object>. List of javadoc-comments (as Object) to convert to markdown format.
Returns: formatted:String. Markdown code from passed javadoc-comments.
Description: Generates markdown code from a list of javadoc-comments.
Javadoc.generateType: Static method. Function.
Parameter: parameters:Object. Overrides Javadoc.DEFAULT_OPTIONS as Object. To see more about properties, go to that static property of Javadoc class.
Returns: output:Promise<String|Array<Object>>. Depending on parameters.format ("json"|"markdown"), it can return an Array or a String.
Description: Finds included files, dismisses excluded files, extracts javadoc-comments, formats them adecuately, and dumps the results into output file, while returning the output asynchronously (as a Promise).
To run the test, clone the repository and run npm run test.
To run the coverage test, clone the repository and run npm run cover.
This project is licensed under WTFPL, which stands for Do What The Fuck You Want To Public License.
This project adheres to semantic versioning 2.0.
To communicate issues here.
FAQs
Unopinionated, simple and powerful documentation generator.
The npm package javadoc receives a total of 47 weekly downloads. As such, javadoc popularity was classified as not popular.
We found that javadoc 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.