pathToSearch
(string, required): The dot-notated path string specifying the location of the integer value to extract from the input object. For example, "person.age"
would retrieve the age
property from the person
object.
obj
(object, required): The input object from which to extract the integer value.
result
(integer): The extracted integer value from the specified path in the input object. If the path is not found or the value is not an integer, the output will be undefined
.obj
input of the Path (Integer) node. This is the object from which you want to extract an integer value.
pathToSearch
input to a dot-notated string representing the path to the desired integer value within the input object.
result
output. You can then connect this output to other nodes in your spell as needed.
age
value from this object, you would:
obj
input of the Path (Integer) node.pathToSearch
input to "age"
.result
output will contain the integer value 30
.zip
value from the nested address
object, you would:
obj
input of the Path (Integer) node.pathToSearch
input to "address.zip"
.result
output will contain the integer value 12345
.pathToSearch
string correctly matches the structure of your input object. Double-check the property names and nesting.result
output will be undefined
. Handle this case appropriately in your spell’s logic.result
output will be undefined
. Ensure that the path points to an integer value.pathToSearch
string. JavaScript is case-sensitive, so "age"
and "Age"
are considered different properties.