mirror of
https://github.com/koalyptus/TableFilter.git
synced 2026-03-18 00:19:50 +01:00
Refactored string module
This commit is contained in:
parent
64f197866a
commit
b6c4fd6675
13 changed files with 182 additions and 238 deletions
|
|
@ -2,12 +2,12 @@
|
|||
* Array utilities
|
||||
*/
|
||||
|
||||
import Str from './string';
|
||||
import {matchCase} from './string';
|
||||
|
||||
export const has = (arr, val, caseSensitive) => {
|
||||
let sCase = Boolean(caseSensitive);
|
||||
for (var i = 0, l = arr.length; i < l; i++) {
|
||||
if (Str.matchCase(arr[i].toString(), sCase) === val) {
|
||||
if (matchCase(arr[i].toString(), sCase) === val) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue