lodash implicit gives "_ is not a function" error

Solution 1:

Lodash's _ is not a function, it is an object, just like the error message indicates.

You are only using Lodash in two places in your code, and only one of those places uses _ as a function. This line of your code:

_(["a", "b", "c"]).filter(itm => itm == "b")

should be:

_.filter(["a", "b", "c"], itm => itm == "b")