Prism · Core
$var
Reads a name bound further up: by $with, or by the as of $map, $filter and the other operators that go through a list. A name that is not in scope refuses with E_VAR_NOT_FOUND.
{ price: 40, rate: 0.2 }{
$with: {
let: {
tax: { $mul: [{ $ref: '$.price' }, { $ref: '$.rate' }] },
},
value: { $var: 'tax' },
},
}8
Runs in this page on the installed package. The input and the expected output are defined by the example.