json_select_many
would be great if this could get the first x values from the element so json_select_many "artists" "name" " ● " "5"
would get the first 5 artists only.
An IfLess
and IfGreater
function would also be useful.
This would be useful when doing something like this for the List of search results especially:
json_foreach "artists"
IfGreater "5"
json_select_many "artists" "name" " ● " "5"
say "... n more"
else
json_select_many "artists" "name" " ● "
sayrest
json_foreach_end
say "|"