FIELD(variable_name, value)
data.field("status") == "Open";
// Pass a variable_name and value to set a field's value
data.field("status", "Completed");
data.field("status") == "Completed";
// Pass an object to set multiple fields
data.field({ status: "Completed", name: "Test" });
If only the variable_name
argument is present, the field's current value is returned. If the optional value
argument is given, the field will be updated (but not saved).
If an object is passed, multiple fields will be set by the object's keys and values.