# find-same-parts

> List the same parts from two given strings

Latest version **1.0.3** (published 2018-07-13) · ISC license · 0 weekly downloads

## Install

```sh
npm install find-same-parts
pnpm add find-same-parts
yarn add find-same-parts
bun add find-same-parts
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2018-07-13 |
| First published | 2018-07-11 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 16.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Neil Chen |
| Maintainers | deepgoing |
| Keywords | String, Similar, Compare, Same, Intersection |

## Links

- npm: https://www.npmjs.com/package/find-same-parts
- Repository: https://github.com/chenjihu/findSameParts
- Homepage: https://github.com/chenjihu/findSameParts#readme
- Issues: https://github.com/chenjihu/findSameParts/issues
- npm.io page: https://npm.io/package/find-same-parts

## Alternatives

- [@mce/gif](https://npm.io/package/@mce/gif.md) — 2.6K weekly downloads
- [cleanse](https://npm.io/package/cleanse.md) — 173 weekly downloads
- [str](https://npm.io/package/str.md) — 127 weekly downloads
- [naming](https://npm.io/package/naming.md) — 95 weekly downloads
- [tap-telco-api](https://npm.io/package/tap-telco-api.md) — 19 weekly downloads

## Recent versions

- 1.0.3 (latest) — 2018-07-13
- 1.0.2 — 2018-07-12
- 1.0.1 — 2018-07-11
- 1.0.0 — 2018-07-11

## README

# find-same-parts
[![build status](https://travis-ci.org/chenjihu/findSameParts.svg?branch=master)](https://github.com/chenjihu/findSameParts?branch=master)
[![Coverage Status](https://coveralls.io/repos/github/chenjihu/findSameParts/badge.svg?branch=master)](https://coveralls.io/github/chenjihu/findSameParts?branch=master)

Find the same parts from two given strings


## Install

```bash
$ npm install find-same-parts --save
```

## Usage

```javascript
findSameParts(firstString, secondString, options);
// will return the sames part in array
// options
// * minStrLength {INT}, set the minimum length of same parts
// * ignoreCase {Boolean}
```

e.g.
```javascript
var findSameParts = require('find-same-parts');

findSameParts('hello world', 'Hello world'); //  ['hello world']
findSameParts('hello world', 'Hello world', {ignoreCase: false});  //  ['ello world']

findSameParts('hello world, bot', 'hello somebody, bot'); // ['hello', 'bot']
findSameParts('hello world, bot', 'hello somebody, bot', {minStrLength: 4}); ['hello']
```

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