There is such a problem, you need to pass the JSON path to the function as a string, for example:
var json_str = "JSON.prop1.prop2.value"; and in the end I need to get it back to normal. You can of course parse regular files and compile it, but it may have some other method, eval does not offer, I have 'use strict'.
The main task is a function that, however, the input receives JSON as a string, and it must return the value "value", or "false" if there is no "value"
String#split()andArray#reduce()- NumminorihSFevalworks fine withuse strict. Although it does not affect the fact that he is out of place here. - Qwertiy ♦