JSTQL-JS-Transform/output_testing/506reduce-reactive-cond-deps-no-uncond.js

10 lines
271 B
JavaScript
Raw Normal View History

// When an object's properties are only read conditionally, we should
// track the base object as a dependency.
function TestOnlyConditionalDependencies(props, other) {
const x = {};
if (other |> foo(%)) {
x.b = props.a.b;
x.c = props.a.b.c;
}
return x;
}