open-index/open-npm huggingface dataset:
npm package: @stradox/vue3-useclickoutside
Description: Use a callback to run actions when a user clicks outside an element
Author: Umar Adejoh
Latest version: 0.0.5

# Vue3-UseClickOutside

A Vue 3 composable that allows you to run actions when clicking outside an element. Useful for closing modals, dropdowns, etc.

## Installation

```bash
$ npm install @stradox/vue3-useclickoutside
```

## Usage

```vue
<script setup lang="ts">
import { ref } from 'vue';
import { useClickOutside } from '@stradox/vue3-useclickoutside';

const relevantRef = ref<HTMLElement | null>(null);

useClickOutside(relevantRef, () => {
  // do something
});
</script>

<template>
  <div>
    <div ref="relevantRef">Click outside me</div>
  </div>
</template>
```
npm package: @strafechat/captcha
Description: A very basic captcha provider for Strafe
Author: ShadowLp174
Latest version: 1.0.41

# Captcha Provider

## Requirements

This captcha middleware requires the express session middleware to be initialized before it is used. It can be installed using `npm install express-session`. For configuration, please refer to the [express-session documentation](https://www.npmjs.com/package/express-session).

## Initialisation

```javascript
const { CaptchaGenerator, middleware } = require("@strafechat/captcha");

const express = require("express");
const app = express();

// initialise express-session middleware here

// the generator can be used separately from the middleware
const generator = new CaptchaGenerator();
app.use(middleware(generator));
```

## Usage

After the middleware has been added, you can access the `generateCaptcha` and `verifyCaptcha` functions on the request object.

```javascript
app.get("/captcha", async (req, res) => {
  res.send({ image: await req.generateCaptcha() });
});
app.post("/captcha", async (req, res) => { // this would require the body-parser middleware
  res.send({ success: req.verifyCaptcha(req.body.captcha) });
});
```
npm package: @straits/eslint-config
Description: straits' ESLint config
Author: peoro
Latest version: 1.0.1


# @straits/eslint-config

> straits' ESLint config

## Installation

```bash
npm install --save-dev @straits/eslint-config
```

## Usage

Set your `.eslintrc.*`'s `extends` field to `"@straits/eslint-config"`:

```json
{
	"extends": "@straits/eslint-config"
}
```

That's it, ESLint will now use this config.
npm package: @straits/eslint-plugin
Description: ESLint preprocessor for JS files using the straits syntax
Author: peoro
Latest version: 1.0.1


# @straits/eslint-plugin ![npm (scoped)](https://img.shields.io/npm/v/@straits/eslint-plugin.svg?style=popout) ![NpmLicense](https://img.shields.io/npm/l/@straits/eslint-plugin.svg?style=popout) ![David](https://img.shields.io/david/peoro/straits-eslint-plugin.svg?style=popout)  ![Travis (.com)](https://img.shields.io/travis/com/peoro/straits-eslint-plugin.svg?style=popout) ![Coveralls github](https://img.shields.io/coveralls/github/peoro/straits-eslint-plugin.svg?style=popout)

> ESLint preprocessor for JS files using the straits syntax

## Installation

```bash
npm install --save-dev @straits/eslint-plugin
```

## Usage

Add `"@straits/eslint-plugin"` to the `plugins` array in your `.eslintrc.*`:

```json
{
	"plugins": [
		"@straits/eslint-plugin"
	]
}
```

That's it, ESLint will now accept straits-syntax.
npm package: @straku/prettier-config
Description: Prettier config for personal projects
Author: Łukasz Strączyński
Latest version: 1.1.0

# Prettier config

Prettier config for my personal projects, most of the settings are the same as prettier defaults. Only following options were changed:

- [`singleQuote`](https://prettier.io/docs/en/options.html#quotes) set to `true`, because I'm too used to them at this point
- [`trailingComma`](https://prettier.io/docs/en/options.html#trailing-commas) set to `es5`, because I like trailing commas, not `all` because although I hope I will never have to support non ES6 environment without transpiling, who knows 🤷‍♂️

Published as scoped npm package [@straku/prettier-config](https://www.npmjs.com/package/@straku/prettier-config)