open-index/open-npm huggingface dataset:
npm package: @jvddavid/authenticator
Description: Biblioteca para geração e verificação de códigos TOTP (Google Authenticator, Microsoft Authenticator, etc.) em Node.js.
Latest version: 1.0.0

# @jvddavid/authenticator

Biblioteca para geração e verificação de códigos TOTP (Google Authenticator, Microsoft Authenticator, etc.) em Node.js.

## Instalação

```sh
pnpm add @jvddavid/authenticator
```

## Uso Básico

```typescript
import {
  generateGoogleAuthKey,
  generateGoogleAuthToken,
  verifyGoogleAuthToken,
  generateTotpUri,
} from '@jvddavid/authenticator'

// Gerar uma chave secreta formatada para Google Authenticator
const secret = generateGoogleAuthKey()
console.log('Chave:', secret)

// Gerar um token TOTP (válido por 30 segundos)
const token = generateGoogleAuthToken(secret)
console.log('Token:', token)

// Verificar se o token é válido
const result = verifyGoogleAuthToken(secret, token)
if (result) {
  console.log('Token válido!')
} else {
  console.log('Token inválido!')
}

// Gerar URI para cadastro em apps autenticadores
const uri = generateTotpUri(secret, 'usuario@exemplo.com', 'MinhaApp')
console.log('URI:', uri)
```

## API

### `generateGoogleAuthKey()`
Gera uma chave secreta base32 formatada para uso em apps autenticadores.

### `generateGoogleAuthToken(secret: string): string`
Gera um token TOTP de 6 dígitos usando a chave informada.

### `verifyGoogleAuthToken(secret: string, token: string): VerifyResult | null`
Verifica se o token informado é válido para a chave. Retorna um objeto com informações ou `null` se inválido.

### `generateTotpUri(secret: string, accountName?: string, issuer?: string, algo?: string, digits?: number, period?: number): string`
Gera uma URI no padrão otpauth para cadastro em apps autenticadores.

## Testes

Execute os testes com:
```sh
pnpm test
```

## Licença
MIT
npm package: @jvddavid/ioredis-extends
Description: A simple wrapper around ioredis to extend its functionality
Author: João Victor Davi de Oliveira
Latest version: 1.0.0

# Redis Extends

`Redis Extends` é um pacote que estende as funcionalidades do ioredis. Ele está disponível no npm como `@jvddavid/ioredis-extends`.

## Instalação

Para instalar o pacote, utilize o npm:

```bash
npm install @jvddavid/ioredis-extends
```

## Uso

Aqui está um exemplo básico de como usar o `Redis Extends`:

```javascript
const RedisExtends = require('@jvddavid/ioredis-extends')

const redisExtends = new RedisExtends(redis)

// Exemplo de uso das funcionalidades estendidas
redisExtends.hexpire('foo', 'field1', 10)
```

## Funcionalidades

- [hexpire](https://redis.io/docs/latest/commands/hexpire/)(key, field, seconds[, callback])

## Contribuição

Contribuições são bem-vindas! Sinta-se à vontade para abrir issues e pull requests no [repositório do GitHub](https://github.com/jvddavid/ioredis-extends).

## Licença

Este projeto está licenciado sob a licença MIT. Veja o arquivo [LICENSE](LICENSE) para mais detalhes.
npm package: @jvddavid/logger
Description: A simple logger for Node.js
Author: João Victor Davi de Oliveira
Latest version: 1.1.4

# Logger

A abstraction of the pino logger to support standard output, file output and rotating file output by the options object.

## Install

```bash
npm i @jvddavid/logger
```

## Use

```javascript
const logger = new Logger({
  name: 'demo',
  level: 'info',
  standard: {
    enabled: true,
    pretty: true
  },
  files: [
    {
      path: 'logs/demo.log',
      pretty: {
        enabled: true,
        colorize: true
      },
      level: 'info'
    }
  ],
  folders: [
    {
      folder: 'logs',
      pattern: 'log-%Y-%M-%d-%N.log',
      maxSize: 10 * 1024 * 1024,
      level: 'info'
    }
  ]
})
logger.log(
  {
    message: 'Hello, world!'
  },
  'Hello, world!'
)
```
npm package: @jvddavid/ts-events
Description: A events implementation for typescript
Author: João Victor Davi de Oliveira
Latest version: 0.0.4

# @jvddavid/ts-events

This is a module where I added the EventMap type to the events library

## Install

```bash
npm install @jvddavid/ts-events
```

## Example

```typescript
import { EventEmitter } from '@jvddavid/ts-events'

type TestEventMap = {
  test: [message: string]
}

const emitter = new EventEmitter<TestEventMap>()

emitter.on('test', (message) => {
  console.log(message)
})

```
npm package: @jvdneut/markdoc
Description: A text markup language for documentation
Author: Ryan Paul
Latest version: 0.4.1-loops-1

<h1 align="center">
  <br>
    <img src="https://user-images.githubusercontent.com/62121649/167893184-a2b69260-ca9e-4a77-a5bc-63b8135ae5db.png" alt="Markdoc" width="260">
  <br>
  <br>
</h1>

<h4 align="center">A powerful, flexible, Markdown-based authoring framework.</h4>

Markdoc is a [Markdown](https://commonmark.org)-based syntax and toolchain for creating custom documentation sites and experiences.  
We designed Markdoc to power [Stripe's public docs](http://stripe.com/docs), our largest and most complex content site.

## Installation

To get started with Markdoc, first install the library:

```shell
npm install @markdoc/markdoc
```

or

```shell
yarn add @markdoc/markdoc
```

and import it in your app:

```js
const Markdoc = require('@markdoc/markdoc');
```

or if you are using ESM

```js
import Markdoc from '@markdoc/markdoc';
```

then use `Markdoc` in your app or tool:

```js
const doc = `
# Markdoc README

{% image src="/logo.svg" /%}
`;

const ast = Markdoc.parse(doc);
const content = Markdoc.transform(ast);
return Markdoc.renderers.react(content, React);
```

Check out [our docs](https://markdoc.dev/docs) for more guidance on how to use Markdoc.

### TypeScript

This is the minimal `tsconfig.json` required to use Markdoc in your TypeScript project:

```json
{
  "compilerOptions": {
    "moduleResolution": "node",
    "target": "esnext", // works with es2015 or greater
    "esModuleInterop": true
  }
}
```

### React

If you are using React, install Markdoc with:

```sh
npm install @markdoc/markdoc react @types/react
```

## Contributing

Contributions and feedback are welcome and encouraged. Check out our [contributing guidelines](.github/CONTRIBUTING.md) on how to do so.

### Development

1. Run `npm install`
1. Run `npm run build`
1. Run the tests using `npm test`

## Code of conduct

This project has adopted the Stripe [Code of conduct](.github/CODE_OF_CONDUCT.md).

## License

This project uses the [MIT license](LICENSE).

## Credits

Special shout out to:

- [@marcioAlmada](https://github.com/marcioAlmada) for providing us with the [@markdoc](https://github.com/markdoc) GitHub org.
- [@koomen](https://github.com/koomen) for gifting us https://markdoc.dev.
npm package: @jvdneut/xml-parser
Description: Simple and lenient XML parser.
Author: Jeroen van der Neut
Latest version: 2.0.8

# @jvdneut/xml-parser

Simple and lenient XML parser.

Parses into a generic (React-like) structure:

```
{
	name: "elementName",
	attributes: {},
	children: []
}
```

To use, install using `npm install @jvdneut/xml-parser`

```
const parse = require('@jvdneut/xml-parser');

const s = '<root attribute="value">text</root>';
// parse with relevant whitespace
const parsed = parse(s);

// parse ignoring whitespace
const parsedIgnoreWhitespace = parse(s, true);
```
npm package: @jvdx/babel-preset
Description: jvdx's babel preset
Author: Joel Voss
Latest version: 2.15.0

# @jvdx/babel-preset

jvdx's babel preset. It includes the following presets and plugins:

**Plugins**
- syntax-import-meta
- transform-regenerator
- macros
- transform-async-to-promises

**Presets**
- env
- react
- typescript

## Installation

(1) Install this preset as well as its peer dependencies:

```bash
# Using npm
$ npm i -D @babel/core @jvdx/babel-preset

# Using yarn
$ yarn add -D @babel/core @jvdx/babel-preset
```

(2) Configure babel:

```json
// babel.config.js
{
	"babel": {
		"presets": ["@jvdx/babel-preset"]
	}
}
```

## Configuration

To configure the included presets/plugins, do not add them to presets or
plugins in your custom babel configuration. Instead, configure them on the
`@jvdx/babel-preset` preset, like so:

```json
{
	"babel": {
		"presets": [
			[
				"@jvdx/babel-preset",
				{
					"assumptions": {/*...*/},
					"preset-env": {/*...*/},
					"preset-react": {/*...*/},
					"preset-typescript": {/*...*/},
				}
			]
		],
	}
}
```

> Notice: To learn more about the available options for each config, visit
> their documentation site.
npm package: @jvdx/eslint-config
Description: jvdx's eslint configuration
Author: Joel Voss
Latest version: 5.9.0

# @jvdx/eslint-config

> Notice: The old configuration can be found in the `v3` branch.

jvdx's ESLint configuration, with sensible defaults for ES6, React and
TypeScript projects.<br>
This configuration is specifically for the new
`eslint.config.js` flat file configuration format.

It exports a `configs` objects with the following rulesets:

- `recommended` - Recommended rules targeting `**/*.{js,jsx,mjs,cjs}` files
- `react` - React rules targeting `**/*.{js,jsx,ts,tsx}` files
  - These rules should be used in conjunction with the `base` or `typescript`
    rulesets
- `typescript` - TypeScript rules targeting `**/*.{ts,tsx,mts,cts}`

> See the [Configurations](#configurations) section for more details.

## Installation

Install configuration as well as peer dependencies:

```bash
$ npm install --save-dev @jvdx/eslint-config eslint
```

## Usage

Use in your `eslint.config.js` file anytime you want to extend one of
the configs:

```js
import jvdxConfig from '@jvdx/eslint-config';

export default [
	// Apply recommended rules
	jvdxConfig.configs.recommended,

	// Apply recommended rules and overwrite some configuration properties
	{
		...jvdxConfig.configs.recommended
		files: ['**/*.js'],
	},

	// Apply recommended + react rules in conjunction
	...jvdxConfig.configs.recommended,
	...jvdxConfig.configs.react,

	// Apply typescript + react rules in conjunction
	...jvdxConfig.configs.typescript,
	...jvdxConfig.configs.react,
];
```

## Configurations

### Recommended

- Extends `eslint:recommended` and `eslint-config-prettier`
- Targets `**/*.{js,jsx,mjs,cjs}` files
- Uses the default parser
- Uses no plugins

### React

- Extends `eslint-plugin-react:recommended`, `eslint-plugin-react:jsx-runtime`
  `eslint-plugin-react-hooks:recommended` and `eslint-plugin-jsx-a11y:recommended`
- Targets `**/*.{js,jsx,ts,tsx}` files
- Uses the default parser
- Uses `react`, `react-hooks` and `jsx-a11y` plugins

### TypeScript

- Extends `@typescript-eslint/recommended`, `eslint:recommended` and
	`eslint-config-prettier`
- Targets `**/*.{ts,tsx,mts,cts}` files
- Uses the `@typescript-eslint/parser` parser
- Uses `@typescript-eslint/eslint-plugin` plugin
npm package: @jvdx/jest-preset
Description: jvdx's jest preset
Author: Joel Voss
Latest version: 2.5.0

# @jvdx/jest-preset

jvdx's jest preset.

## Installation

(1) Install this configuration:

```bash
# Using npm
$ npm i -D @jvdx/jest-preset

# Using yarn
$ yarn add -D @jvdx/jest-preset
```

(2) Extend jest configuration:

```json
{
  "preset": "@jvdx/jest-preset"
}
```
npm package: @jvdx/prettier-config
Description: jvdx's prettier configuration
Author: Joel Voss
Latest version: 0.3.4

# @jvdx/prettier-config

jvdx's prettier configuration.

## Installation

(1) Install this configuration:

```bash
# Using npm
$ npm i -D @jvdx/prettier-config

# Using yarn
$ yarn add -D @jvdx/prettier-config
```

(2) Configure prettier in your `package.json`:

```json
{
  "prettier": "@jvdx/prettier-config"
}
```