open-index/open-npm huggingface dataset:
npm package: @jjangga0214/commitlint-config
Description: A sharable config package and development environment for commitlint
Author: GIL B. Chan
Latest version: 1.1.0

# `@jjangga0214/commitlint-config`

A [Sharcable Config](https://commitlint.js.org/#/reference-configuration?id=shareable-configuration) package for [commitlint](https://commitlint.js.org/#/).

## Installation

```sh
npm install --save-dev @jjangga0214/commitlint-config
# or
yarn add --dev @jjangga0214/commitlint-config
# or
pnpm add --save-dev @jjangga0214/commitlint-config
```

And you should also install `peerDependencies` manually.
Check out package.json or `npm info`.

```sh
# This does not install them all. This just show them on terminal.
npm info "@jjangga0214/commitlint-config@latest" peerDependencies
```

Or install them all by [`install-peerdeps`](https://openbase.com/js/install-peerdeps/documentation).

```sh
# For npm
npx install-peerdeps --dev @jjangga0214/commitlint-config
# For yarn
npx install-peerdeps --yarn --dev @jjangga0214/commitlint-config
# For pnpm
npx install-peerdeps --pnpm --dev @jjangga0214/commitlint-config
```

## Development

Check out the official docs for [Sharable Config](https://commitlint.js.org/#/reference-configuration?id=shareable-configuration)

## Usage

**.commitlint.config.js**:

```js
module.exports = {
  // REF: https://commitlint.js.org/#/concepts-shareable-config
  extends: ["@jjangga0214/commitlint-config"],
  // rules: { ... } // You can override it.
};
```

## CJS and ESM

This package is intentionally CJS.
Once commitlint starts supporting ESM, this package becomes also free to migrate.
Refer to <https://github.com/conventional-changelog/commitlint/issues/3705>
npm package: @jjangga0214/markdownlint-config
Description: A sharable config package for markdownlint
Author: GIL B. Chan
Latest version: 1.1.0

# `@jjangga0214/markdownlint-config`

A sharable config package for [`markdownlint-cli`](https://github.com/igorshubovych/markdownlint-cli).

## Installation

```sh
npm install --save-dev @jjangga0214/markdownlint-config
# or
yarn add --dev @jjangga0214/markdownlint-config
# or
pnpm add --save-dev @jjangga0214/markdownlint-config
```

And you should also install `peerDependencies` manually.
Checkout package.json or `npm info`.

```sh
# This does not install them all. This just show them on terminal.
npm info "@jjangga0214/markdownlint-config@latest" peerDependencies
```

Or install them all by [`install-peerdeps`](https://openbase.com/js/install-peerdeps/documentation).

```sh
# For npm
npx install-peerdeps --dev @jjangga0214/markdownlint-config
# For yarn
npx install-peerdeps --yarn --dev @jjangga0214/markdownlint-config
# For pnpm
npx install-peerdeps --pnpm --dev @jjangga0214/markdownlint-config
```

## Note

- There're [`markdownlint-cli`](https://www.npmjs.com/package/markdownlint-cli) and [`markdownlint-cli2`](https://www.npmjs.com/package/markdownlint-cli2). This package works with the former. This may or may not work with the latter.
- There's [`igorshubovych/markdownlint-cli#97`](https://github.com/igorshubovych/markdownlint-cli/issues/97) for extending sharable config, and/or autodiscovery of .js config file. Once the discussion is settled, the usage below might ought to be edited.

## Usage

**.markdownlint.json**:

```jsonc
{
  "extends": "@jjangga0214/markdownlint-config"
  // You can override/add rules here.
}
```

**.markdownlintignore** (Optional):

```txt
.git
**/node_modules
# specify any patterns you need
```
npm package: @jjangga0214/prettier-config
Description: A sharable config package for prettier
Author: GIL B. Chan
Latest version: 3.1.0

# `@jjangga0214/prettier-config`

A sharable config package and development environment for [prettier](https://prettier.io).

## Installation

```sh
npm install --save-dev @jjangga0214/prettier-config
# or
yarn add --dev @jjangga0214/prettier-config
# or
pnpm add --save-dev @jjangga0214/prettier-config
```

And you should also install `peerDependencies` manually.
Check out package.json or `npm info`.

```sh
# This does not install them all. This just show them on terminal.
npm info "@jjangga0214/prettier-config@latest" peerDependencies
```

Or install them all by [`install-peerdeps`](https://openbase.com/js/install-peerdeps/documentation).

```sh
# For npm
npx install-peerdeps --dev @jjangga0214/prettier-config
# For yarn
npx install-peerdeps --yarn --dev @jjangga0214/prettier-config
# For pnpm
npx install-peerdeps --pnpm --dev @jjangga0214/prettier-config
```

## Usage

**package.json**:

```jsonc
{
  "name": "your-cool-library",
  "prettier": "@jjangga0214/prettier-config"
  // Other fields are ommitted for brevity
}
```

Or you can import it into the javascript config file.

**.prettierrc.js**:

```js
import config from '@jjangga0214/prettier-config'

export default config
```

## Development

- [REF](https://prettier.io/docs/en/configuration.html#sharing-configurations)
npm package: @jjangga0214/tsconfig
Description: A sharable config package for Typescript
Author: GIL B. Chan
Latest version: 4.0.0

# `@jjangga0214/tsconfig`

A sharable config package for [Typescript](https://www.typescriptlang.org).

## Installation

```sh
npm install --save-dev @jjangga0214/tsconfig
# or
yarn add --dev @jjangga0214/tsconfig
# or
pnpm add --save-dev @jjangga0214/tsconfig
```

And you should also install `peerDependencies` manually.
Checkout package.json or `npm info`.

```sh
# This does not install them all. This just show them on terminal.
npm info "@jjangga0214/tsconfig@latest" peerDependencies
```

Or install them all by [`install-peerdeps`](https://openbase.com/js/install-peerdeps/documentation).

```sh
# For npm
npx install-peerdeps --dev @jjangga0214/tsconfig
# For yarn
npx install-peerdeps --yarn --dev @jjangga0214/tsconfig
# For pnpm
npx install-peerdeps --pnpm --dev @jjangga0214/tsconfig
```

## Note

- Path-related fields, like `outDir`, `rootDir`, `baseUrl`, `paths`, `tsBuildInfoFile`, etc, are not set in this config. That's because Typescript resolves paths relative to the configuration file. Thus, you need to configure it manually. [REF](https://github.com/Microsoft/TypeScript/issues/29172)
- This package includes not only tsconfig.json, but also packages needed in typescript development environment, like [tsconfig-paths](https://github.com/dividab/tsconfig-paths) and so on.
- [`ts-node`](https://typestrong.org/ts-node/) is configured to use [`swc`](https://github.com/swc-project/swc) under the hood. [REF](https://typestrong.org/ts-node/docs/transpilers)

## Usage for a single-project repo

**tsconfig.json**:

```jsonc
{
  "extends": "@jjangga0214/tsconfig/tsconfig.json",
  "compilerOptions": {
    "outDir": "dist",
    "rootDir": "./",
    "baseUrl": "./",
    "paths": {
      "@your-scope/foo": ["src/foo"],
      "#foo": ["src/foo"]
    }
  }
}
```

### Usage for a monorepo

**tsconfig.json**:

```jsonc
{
  "extends": "@jjangga0214/tsconfig/tsconfig.json",
  "compilerOptions": {
    "outDir": "dist",
    "rootDir": "./",
    "baseUrl": "./",
    "paths": {
      "@your-scope/*": [
        "backends/*/src",
        "frontends/*/src",
        "libs/*/src",
        "workflows/*/src"
      ],
      "#foo/*": ["libs/foo/src/*"],
      "#bar/*": ["libs/bar/src/*"],
      // ... (others are omitted for brevity)
      "#*": [
        "backends/*/src",
        "frontends/*/src",
        "libs/*/src",
        "workflows/*/src"
      ]
    }
  }
}
```

## Usage for import

```js
import tsconfig from "@jjangga0214/tsconfig";
```
npm package: @jjasonn.stone/design-system
Description: Design system for [Livepeer](https://livepeer.org/) products.
Latest version: 2.1.4

# Livepeer Design System

Design system for [Livepeer](https://livepeer.org/) products.

## Documentation

Visit [https://livepeer-design-system.vercel.app/](https://livepeer-design-system.vercel.app/) to view the design system reference components.

## Usage

```
yarn add @livepeer/design-system
```

## License

Licensed under the [MIT](./LICENSE) license.
npm package: @jjavery/blitz
Description: Sets of dice representing attackers and defenders are rolled one or more times to determine casualties for each side
Author: James P. Javery
Latest version: 1.0.0

# @jjavery/blitz

Sets of dice representing attackers and defenders are rolled one or more times to determine casualties for each side

## Installation

Install with NPM

```shell
$ npm install @jjavery/blitz
```

## Example

### game.js:

```javascript
const blitz = require('@jjavery/blitz');

// Attack with 5, defend with 3
const result = blitz(5, 3);

/*
result will look something like this:

{
  startingAttackers: 5,
  startingDefenders: 4,
  lostAttackers: 5,
  lostDefenders: 1,
  remainingAttackers: 0,
  remainingDefenders: 3,
  winner: 'defender',
  rounds: [
    [[5, 4, 3], [6, 4], 3, 4],
    [[6, 3, 2], [5, 3], 2, 3],
    [[5, 1], [5, 4], 0, 3]
  ],
  rolls: 14
}
*/

```

# API Reference


## blitz(startingAttackers, startingDefenders, options) ⇒ BlitzResult
Performs a blitz


| Param | Type | Default | Description |
| --- | --- | --- | --- |
| startingAttackers | number |  | The number of attackers to start with |
| startingDefenders | number |  | The number of defenders to start with |
| options | Object | `{}` | Optional parameters |
| options.maxAttackDice | number | `3` | Maximum number of attacker dice rolled during a round |
| options.maxDefendDice | number | `2` | Maximum number of defender dice rolled during a round |
| options.diceSides | number | `6` | Number of sides per die |
| options.stopLoss | number | `0` | Stop when the number of attackers has reached this number |
| options.maxRounds | number | `Number.MAX_SAFE_INTEGER` | Maximum number of rounds to perform |
| options.rolls | Array |  | Integer array to use for dice rolls instead of Math.random() |

## BlitzResult : Object
**Properties**

| Name | Type | Description |
| --- | --- | --- |
| startingAttackers | number | The number of attackers at start |
| startingDefenders | number | The number of defenders at start |
| lostAttackers | number | The number of attackers lost |
| lostDefenders | number | The number of defenders lost |
| remainingAttackers | number | The number of attackers remaining |
| remainingDefenders | number | The number of defenders remaining |
| winner | string | `attacker` or `defender` or null |
| rounds | Array | The accumulated rounds completed |
| rolls | number | The number of times a die was rolled |


---

Copyright &copy; 2021 James P. Javery [@jjavery](https://github.com/jjavery)
npm package: @jjavery/dmd-jjavery
Description: Plugin for jsdoc2md to produce markdown suitable for API documentation
Author: James P. Javery
Latest version: 0.1.0

# dmd-jjavery
Plugin for [jsdoc2md](https://github.com/jsdoc2md/jsdoc-to-markdown) to produce markdown suitable for API documentation.

## Install and use
In the project requiring this plug-in, install it as a devDependency:
```
$ npm install @jjavery/dmd-jjavery --save-dev
```

Then pass the plug-in name to `jsdoc2md` or `dmd` when generating your docs:
```
$ jsdoc2md --plugin @jjavery/dmd-jjavery --files src/*.js
```

* * *

&copy; 2015-16 Lloyd Brookes <75pound@gmail.com>.
npm package: @jjavery/mongoose-lean-queries
Description: Mongoose plugin to use lean queries by default
Author: James P. Javery
Latest version: 0.1.0

# mongoose-lean-queries

Mongoose plugin to use lean queries by default

## Installation

Install with NPM

```shell
$ npm install @jjavery/mongoose-lean-queries
```

## Example

```javascript
const mongoose = require('mongoose');
const mongooseLeanQueries = require('@jjavery/mongoose-lean-queries');

const schema = new mongoose.Schema({
  field: String
});

// Apply the plugin to a single schema
schema.plugin(mongooseLeanQueries);

// Or apply the plugin to all schemas
mongoose.plugin(mongooseLeanQueries);

const Thing = mongoose.Model('thing', schema);

async function getData(id) {
  const thing1 = await Thing.findById(id);

  // thing1 is a lean pojo with the result of _id.toString() copied to id

  const thing2 = await Thing.findById(id).lean(false);

  // thing2 is a Mongoose Document
}
```

## To Do
* more tests
* option to disable copying \_id to id
* honor schema option id === false

---

Copyright &copy; 2021 James P. Javery [@jjavery](https://github.com/jjavery)
npm package: @jjavery/oddjob-mongodb
Description: MongoDB connector for @jjavery/oddjob
Author: James P. Javery
Latest version: 0.15.0

# oddjob-mongodb

This is the MongoDB connector for @jjavery/oddjob

https://github.com/jjavery/oddjob

---

Copyright &copy; 2022 James P. Javery [@jjavery](https://github.com/jjavery)
npm package: @jjavery/oddjob-sqlite
Description: SQLite connector for @jjavery/oddjob
Author: James P. Javery
Latest version: 0.15.0

# oddjob-mongodb

This is the SQLite connector for @jjavery/oddjob

https://github.com/jjavery/oddjob

---

Copyright &copy; 2022 James P. Javery [@jjavery](https://github.com/jjavery)
npm package: @jjbenitez/nest-knex
Description: <h1 align="center"></h1>
Latest version: 1.0.2

<h1 align="center"></h1>

<div align="center">
  <a href="http://nestjs.com/" target="_blank">
    <img src="https://nestjs.com/img/logo_text.svg" width="150" alt="Nest Logo" />
  </a>
</div>

<h3 align="center">NestMysql2 -- generated by @nestjsplus/dyn-schematics</h3>

<div align="center">
  <a href="https://nestjs.com" target="_blank">
    <img src="https://img.shields.io/badge/built%20with-NestJs-red.svg" alt="Built with NestJS">
  </a>
  <a href="https://github.com/nestjsplus/dyn-schematics" target="_blank">
    <img src="https://img.shields.io/badge/Built%20with-%40nestjsplus%2Fdyn--schematics-brightgreen" alt="Built with @nestjsplus/dyn-schematics">
  </a>
</div>

This dynamic module was generated with [Nest Dynamic Package Generator Schematics](https://github.com/nestjsplus/dyn-schematics).  You can read more about using the generator [here](https://github.com/nestjsplus/dyn-schematics).

### Installation

To install this generated project:

```bash
npm install
```

(or yarn equivalent)

### Running

If you selected `yes` for the question `Generate a testing client?`, a small testing module was automatically generated
called NestMysql2ClientModule.  You can test that the template was properly generated by running

```bash
npm run start:dev
```

Then connect to [http://localhost:3000](http://localhost:3000).

### Customizing

The files in the project have comments that should help guide you.

You can also refer to [this article](https://dev.to/nestjs/advanced-nestjs-how-to-build-completely-dynamic-nestjs-modules-1370) for details on the concepts behind this module pattern.

You can read more about using the generator [here](https://github.com/nestjsplus/dyn-schematics).

### About @nestjsplus/dyn-schematics

[Nest Dynamic Package Generator Schematics](https://github.com/nestjsplus/dyn-schematics) generates a starter template for building NestJS dynamic packages.  It uses the `@nestjs/cli` core package, and provides customized schematics for generating modular NestJS applications.  See [here](https://github.com/nestjsplus/dyn-schematics) for the full set of available schematics, and documentation.
npm package: @jjbenitez/nest-mysql2
Description: <h1 align="center"></h1>
Latest version: 1.0.1

<h1 align="center"></h1>

<div align="center">
  <a href="http://nestjs.com/" target="_blank">
    <img src="https://nestjs.com/img/logo_text.svg" width="150" alt="Nest Logo" />
  </a>
</div>

<h3 align="center">NestMysql2 -- generated by @nestjsplus/dyn-schematics</h3>

<div align="center">
  <a href="https://nestjs.com" target="_blank">
    <img src="https://img.shields.io/badge/built%20with-NestJs-red.svg" alt="Built with NestJS">
  </a>
  <a href="https://github.com/nestjsplus/dyn-schematics" target="_blank">
    <img src="https://img.shields.io/badge/Built%20with-%40nestjsplus%2Fdyn--schematics-brightgreen" alt="Built with @nestjsplus/dyn-schematics">
  </a>
</div>

This dynamic module was generated with [Nest Dynamic Package Generator Schematics](https://github.com/nestjsplus/dyn-schematics).  You can read more about using the generator [here](https://github.com/nestjsplus/dyn-schematics).

### Installation

To install this generated project:

```bash
npm install
```

(or yarn equivalent)

### Running

If you selected `yes` for the question `Generate a testing client?`, a small testing module was automatically generated
called NestMysql2ClientModule.  You can test that the template was properly generated by running

```bash
npm run start:dev
```

Then connect to [http://localhost:3000](http://localhost:3000).

### Customizing

The files in the project have comments that should help guide you.

You can also refer to [this article](https://dev.to/nestjs/advanced-nestjs-how-to-build-completely-dynamic-nestjs-modules-1370) for details on the concepts behind this module pattern.

You can read more about using the generator [here](https://github.com/nestjsplus/dyn-schematics).

### About @nestjsplus/dyn-schematics

[Nest Dynamic Package Generator Schematics](https://github.com/nestjsplus/dyn-schematics) generates a starter template for building NestJS dynamic packages.  It uses the `@nestjs/cli` core package, and provides customized schematics for generating modular NestJS applications.  See [here](https://github.com/nestjsplus/dyn-schematics) for the full set of available schematics, and documentation.