1
0
Fork 0
mirror of https://github.com/pawelmalak/flame.git synced 2025-07-27 14:59:37 +02:00

Added app descriptions to local search parser

This commit is contained in:
Paweł Malak 2022-01-08 12:48:33 +01:00
parent 6d8ce5361a
commit 396c442062
2 changed files with 7 additions and 2 deletions

View file

@ -64,8 +64,10 @@ export const Home = (): JSX.Element => {
if (localSearch) {
// Search through apps
setAppSearchResult([
...apps.filter(({ name }) =>
new RegExp(escapeRegex(localSearch), 'i').test(name)
...apps.filter(({ name, description }) =>
new RegExp(escapeRegex(localSearch), 'i').test(
`${name} ${description}`
)
),
]);