T
T
Tereverda2021-06-25 20:31:14
JavaScript
Tereverda, 2021-06-25 20:31:14

Object filtering in JS?

There is an object with values, you need to filter it - remove what does not fit the rules.
As far as I understand, the arr.filter method is applicable only to arrays?
To filter the values ​​of an object, you need to convert it to an array, and only then filter it?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
Nadim Zakirov, 2021-06-25
@Tereverda

To filter objects, it is not necessary to use any special methods, loops are enough.

D
Dmitry Belyaev, 2021-06-25
@bingo347

https://developer.mozilla.org/en/docs/Web/JavaScri...
https://developer.mozilla.org/en/docs/Web/JavaScri...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question