mgeneratejs
mgeneratejs copied to clipboard
Use case of $pick not clear
I'm a bit confused by the point of $pick
. I have an example like:
"$pick": {
"array": [
"75009",
"75010",
"75008",
"75011"
]
}
and had assumed that by default it would pick an element at random, but it always picks element
= 0. How can I randomize this and specify a value for element
?
I guess I should be using $choose
instead - but then I don't understand what the point of $pick
is.