1.0.0 • Published 8 years ago

string-contains-string v1.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
8 years ago

string-contains-string

NPM version Build Status Coverage Status

Code Climate Dependencies DevDependencies

PRs Welcome Commitizen friendly semantic-release

Check if one of two strings contains the other

Install

npm install --save string-contains-string

Usage

import stringContainsString from 'string-contains-string'

stringContainsString('hello', 'world')
// => false

stringContainsString('hello', 'ell')
// => true

stringContainsString('ell', 'hello')
// => true

API

stringContainsString(str1, str2)

Returns a boolean if str1 contains str2 or str2 contains str1.

str1

type: string

A string to test.

str2

type: string

Another string to test.

LICENSE

MIT © Dustin Specker