npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

doculatte

v1.1.0

Published

> A JavaScript Docblockr-to-Markdown documentation writer.

Downloads

7

Readme

Doculatte

A JavaScript Docblockr-to-Markdown documentation writer.

Gif example of Doculatte

Install

npm i -g doculatte

Usage

$ doculatte help

    Doculatte

    Recursively build markdown docs for JS files

    Command                 Exec
    ---------------         ---------------

    doculatte help          Display help
    doculatte run [file]    Generate doc files or pass [file] as file/to/path to generate doc for specific file

    Flags                   Function
    ---------------         ---------------
    -i                      Ignore folders (paths as folders/files divided by commas)
    -n                      Output doc name (only works for singular files)
    -t                      Output name type VALUES=[snake|start|camel|kebab] (default is snake, overriden by -n)
    -p                      Prefix doc file name (overriden by -n)
    -s                      Suffix doc file name (overriden by -n, default is "docs")
    -u                      Set output doc name to uppercase

    Examples
    ---

    $ doculatte run
    > # recursively generate docs files
    > Generated: path/to/file_docs.md

    $ doculatte run path/to/file.js
    > Generated: path/to/file_docs.md

    $ doculatte run path/to/file.js -p prefix -s suffix -u
    > Generated: path/to/PREFIX_FILE_SUFFIX.md

    $ doculatte run path/to/file.js -p prefix -s suffix -u -t kebab
    > Generated: path/to/PREFIX-FILE-SUFFIX.md

    $ doculatte run path/to/file.js -p prefix -s suffix -t camel
    > Generated: path/to/prefixFileSuffix.md

    $ doculatte run path/to/file.js -p prefix -s suffix -t start
    > Generated: path/to/Prefix File Suffix.md

    $ doculatte run path/to/file.js -n custom-name
    > Generated: path/to/custom-name.md

    $ doculatte run -i folderOne,folderTwo,folderThree
    > NOT Generated: path/to/folderOne/custom-name.md ...

    Built by Dennis O'Keeffe

    Twitter: @dendribbles
    Github: https://github.com/okeeffed

Quick Usage with npx

npx doculatte run

Basic Example

Given a basic folder structure:

.
├── five
│   └── index.js
├── four
│   └── index.js
├── one
│   └── index.js
├── seven
│   └── index.js
├── six
│   └── index.js
├── three
│   └── index.js
└── two
    └── index.js

With example index.js:

/**
 * This file is a test example to generate DOCS.md
 * 
 * @author Dennis O'Keeffe
 */
class Mathematics {
    /**
     * Multiply the two args
     * 
     * @param {number} a 
     * @param {number} b
     * @memberof Mathematics
     */
    multiply = (a, b) => {
        return a * b;
    }

    /**
     * Add the two args together
     * 
     * @param {number} a 
     * @param {number} b 
     * @memberof Mathematics
     */
    add = (a, b) => {
        return a + b;
    }

    /**
     * Subtract the two args together
     * 
     * @param {number} a 
     * @param {number} b 
     * @memberof Mathematics
     */
    subtract = (a, b) => {
        return a - b;
    }
}

Running:

doculatte run

Will produce structure:

.
├── five
│   ├── index.js
│   └── index_docs.md
├── four
│   ├── index.js
│   └── index_docs.md
├── one
│   ├── index.js
│   └── index_docs.md
├── seven
│   ├── index.js
│   └── index_docs.md
├── six
│   ├── index.js
│   └── index_docs.md
├── three
│   ├── index.js
│   └── index_docs.md
└── two
    ├── index.js
    └── index_docs.md

With index_docs.md looking like:

<a name="Mathematics"></a>

## Mathematics
This file is a test example to generate DOCS.md

**Kind**: global class  
**Author**: Dennis O'Keeffe  

* [Mathematics](#Mathematics)
    * [.multiply](#Mathematics.multiply)
    * [.add](#Mathematics.add)
    * [.subtract](#Mathematics.subtract)

<a name="Mathematics.multiply"></a>

### Mathematics.multiply
Multiply the two args

**Kind**: static property of [<code>Mathematics</code>](#Mathematics)  

| Param | Type |
| --- | --- |
| a | <code>number</code> | 
| b | <code>number</code> | 

<a name="Mathematics.add"></a>

### Mathematics.add
Add the two args together

**Kind**: static property of [<code>Mathematics</code>](#Mathematics)  

| Param | Type |
| --- | --- |
| a | <code>number</code> | 
| b | <code>number</code> | 

<a name="Mathematics.subtract"></a>

### Mathematics.subtract
Subtract the two args together

**Kind**: static property of [<code>Mathematics</code>](#Mathematics)  

| Param | Type |
| --- | --- |
| a | <code>number</code> | 
| b | <code>number</code> | 

FAQ

TBD.

License

MIT © Dennis O'Keeffe