# flac

> Find, Load and make the Cache

Latest version **0.3.0** (published 2013-02-14) · 0 weekly downloads

## Install

```sh
npm install flac
pnpm add flac
yarn add flac
bun add flac
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; low quality score; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.3.0 |
| Published | 2013-02-14 |
| First published | 2012-12-20 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.4 |
| Dependencies | 2 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Fedor Golubev |
| Maintainers | gregof |

## Links

- npm: https://www.npmjs.com/package/flac
- Repository: https://github.com/gregof/flac
- npm.io page: https://npm.io/package/flac

## Dependencies (2)

- [abc](https://npm.io/package/abc.md) 0.5.x
- [fsa](https://npm.io/package/fsa.md) 0.5.x

## Recent versions

- 0.3.0 (latest) — 2013-02-14
- 0.2.2 — 2013-02-06
- 0.2.1 — 2012-12-28
- 0.2.0 — 2012-12-21
- 0.1.0 — 2012-12-20

## README

# FLAC
Find, Load and make the Cache.
Caching made by [fsa](https://github.com/gregof/fsa).

If your filters are changed, you have to `clearCache`, because filters doesn't apply to cached objects.

## Example
File structure:
```
test
  package.json
  a
    module.json
  b
    module.json
```
Define filters and exec `flac.find` for `test` directory.
```javascript
var flacOptions = {
    filters: [
        {
            name: 'module',
            test: function (file) {
                return file === 'module.json'
            }
        },
        {
            name: 'package', 
            test: function (file) {
                return file === 'package.json'
            }
        }
    ],
    noCache: false, // not required, default value 'false'
    cacheDir: '.custom' // not required, default value '.flac'
};
flac.find('test', flacOptions, function (res) {
    // print result
})
```
Result:
```json
[
    {
        "filter": "module",
        "file": "a/module.json",
        "text": "..."
    },
    {
        "filter": "module",
        "file": "b/module.json",
        "text": "..."
    },
    {
        "filter": "package",
        "file": "package.json",
        "text": "..."
    }
]
```

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