# ngx-pipe-search-by

> Filter values by a property in array of objects

Latest version **1.0.0** (published 2019-09-30) · GPLV3 license · 0 weekly downloads

## Install

```sh
npm install ngx-pipe-search-by
pnpm add ngx-pipe-search-by
yarn add ngx-pipe-search-by
bun add ngx-pipe-search-by
```

## Health

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

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2019-09-30 |
| First published | 2019-09-26 |
| Weekly downloads | 0 |
| License | GPLV3 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 133.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Miguel Lopez |
| Maintainers | mikeg96 |
| Keywords | search, array, object, objects, pipe, angular6, angular7, angular8 |

## Links

- npm: https://www.npmjs.com/package/ngx-pipe-search-by
- Repository: https://github.com/MikeG96/ngx-pipe-search-by
- Homepage: https://github.com/MikeG96/ngx-pipe-search-by#readme
- Issues: https://github.com/MikeG96/ngx-pipe-search-by/issues
- npm.io page: https://npm.io/package/ngx-pipe-search-by

## Dependencies (1)

- [tslib](https://npm.io/package/tslib.md) ^1.9.0

## Alternatives

- [byte-size](https://npm.io/package/byte-size.md) — 2.1M weekly downloads
- [speed-limiter](https://npm.io/package/speed-limiter.md) — 16.0K weekly downloads
- [@powersync/node](https://npm.io/package/@powersync/node.md) — 10.9K weekly downloads
- [@ledgerhq/coin-cardano](https://npm.io/package/@ledgerhq/coin-cardano.md) — 1.0K weekly downloads
- [@jayesol/jayeson.lib.streamfinder](https://npm.io/package/@jayesol/jayeson.lib.streamfinder.md) — 1.0K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2019-09-30
- 0.0.1-beta.6 — 2019-09-27
- 0.0.1-beta.5 — 2019-09-27
- 0.0.1-beta.4 — 2019-09-27
- 0.0.1-beta.3 — 2019-09-27
- 0.0.1-beta.2 — 2019-09-26
- 0.0.1-beta.1 — 2019-09-26
- 0.0.1-beta.0 — 2019-09-26

## README

# ngx-pipe-search-by

Search in array of object by property

**Arguments**

| Param            |      Type       | Default | Details                                                                          |
| ---------------- | :-------------: | ------: | -------------------------------------------------------------------------------- |
| collection       |     `Array`     |       - | The collection to filter                                                         |
| searchWord       |    `string`     |       - | String to search                                                                 |
| propertiesSearch | `Array<string>` |       - | Property to look for. Examples: `[name]`, `[name, client.name, client.pet.name`] |
| sensitive        |    `boolean`    |    true | Case sensitive                                                                   |

# Install

```
npm install ngx-pipe-search-by --save
```

# Usage

Import `PipeSearchByModule` to your module

```typescript
import { NgModule } from "@angular/core";
import { BrowserModule } from "@angular/platform-browser";
import { AppComponent } from "./app";

import { PipeSearchByModule } from "ngx-pipe-search-by";

@NgModule({
  imports: [BrowserModule, PipeSearchByModule],
  declarations: [AppComponent],
  bootstrap: [AppComponent]
})
export class AppModule {}
```

**In HTML Template**

```html
<div
  *ngFor="let item of collection | searchBy: searchWord: propertiesSearch: sensitive"
>
  <!-- HERE HTML -->
</div>
```

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