# find-by-ext

> Find all files in folder's by extname.

Latest version **1.0.4** (published 2024-02-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install find-by-ext
pnpm add find-by-ext
yarn add find-by-ext
bun add find-by-ext
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2024-02-23 |
| First published | 2022-05-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Felipe Izolan |
| Maintainers | felipeizolan |
| Keywords | fs, path, find, search, folder, file, files |

## Links

- npm: https://www.npmjs.com/package/find-by-ext
- Repository: https://github.com/FelipeIzolan/find-by-ext
- Homepage: https://github.com/FelipeIzolan/find-by-ext#readme
- Issues: https://github.com/FelipeIzolan/find-by-ext/issues
- npm.io page: https://npm.io/package/find-by-ext

## Alternatives

- [unionfs](https://npm.io/package/unionfs.md) — 2.2M weekly downloads
- [path-starts-with](https://npm.io/package/path-starts-with.md) — 35.9K weekly downloads
- [redzip](https://npm.io/package/redzip.md) — 1.2K weekly downloads
- [vscode-anymatch](https://npm.io/package/vscode-anymatch.md) — 848 weekly downloads
- [@ledgerhq/coin-filecoin](https://npm.io/package/@ledgerhq/coin-filecoin.md) — 793 weekly downloads

## Recent versions

- 1.0.4 (latest) — 2024-02-23
- 1.0.3 — 2022-12-12
- 1.0.2 — 2022-08-14
- 1.0.1 — 2022-05-17
- 1.0.0 — 2022-05-17

## README

# 🐀 find-by-ext

<img width=312 src="https://img.freepik.com/premium-vector/vintage-illustration-sitting-fat-rat-oldschool-drawing-fat-mouse-vector-sketch_905000-68.jpg">

Find files inside folders by extname.

## 🚀 Installation

```
npm install find-by-ext
```

## 🍋 Usage

```ts
import { findByExt, findByExtOne, findByExtLimit } from "../index";

const __dirname = path.resolve();

var scripts = findByExt(__dirname, [".cmd", ".sh", ".ps1", ".bat"]);
var image = findByExtOne(__dirname, [".png", ".jpg", ".gif", ".webp"]);
var _4doc = findByExtLimit(__dirname, [".txt", ".md", ".markdown"], 4);
```

## 🔖 Reference

- **findByExt(dirname, whitelist)**
- **findByExtOne(dirname, whitelist)**
- **findByExtLimit(dirname, whitelist, limit)**

## 📜 License

- [find-by-ext](https://github.com/FelipeIzolan/find-by-ext) - MIT

---
_Source: https://npm.io/package/find-by-ext · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
