enkidevs / enkidevs/react-search-input

Regex not working in searchTerm value

Open
#139 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
297
Forks
71
PR merge metrics
No merged PRs in 30d

Description

Regular expression is not working with createFilter method. Below is the code for using regex:

```
let re = new RegExp(this.state.searchStatus,"g");
newData = data.filter(createFilter(re, STATUS_KEY_TO_FILTERS));
```

Is it possible to use regex in it?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.