render-help
Creates a nice output for a CLI --help
Last updated 7 years ago by zkochan .
MIT · Repository · Original npm · Tarball · package.json
$ npm install render-help 
SYNC missed versions from official npm registry.

render-help

Creates a nice output for a CLI --help

npm version

Installation

<pnpm|yarn|npm> add render-help

Usage

const renderHelp = require('./lib')

const output = renderHelp({
  usages: ['pnpm install [options]'],
  aliases: ['i'],
  description: 'Install all dependencies',
  descriptionLists: [
    {
      title: 'Options',
      list: [
        {
          name: '--force',
          shortAlias: '-f',
          description: 'Do some dangerous things'
        },
        {
          name: '--lockfile-only',
          description: "Don't create node_modules. Just generate pnpm-lock.yaml"
        }
      ]
    }
  ],
  url: 'https://pnpm.js.org/en/cli/install'
})
console.log(output)
// Usage: pnpm install [options]
//
// Alias: i
//
// Install all dependencies
//
// Options:
//   -f, --force               Do some dangerous things
//       --lockfile-only       Don't create node_modules. Just generate pnpm-lock.yaml
//
// Visit https://pnpm.js.org/en/cli/install for documentation about this command.

License

MIT © Zoltan Kochan

Current Tags

  • 2.0.0                                ...           latest (9 months ago)
  • 1.0.2                                ...           next (6 years ago)

6 Versions

  • 2.0.0                                ...           9 months ago
  • 1.0.3                                ...           4 years ago
  • 1.0.2                                ...           6 years ago
  • 1.0.1                                ...           6 years ago
  • 1.0.0                                ...           7 years ago
  • 0.0.0                                ...           7 years ago
Maintainers (1)
Downloads
Total 18
Today 0
This Week 0
This Month 12
Last Day 0
Last Week 6
Last Month 6
Dependencies (1)
Dev Dependencies (8)

© 2010 - cnpmjs.org x YWFE | Home | YWFE