Trying to optimize my React app… should one combine setState statements when possible or it is best practice to keep them separate?
setLength(10)
setLengthPercentage(10)
setMarks(["foo", "bar"])
vs
setAll({
length: 10,
lengthPercentage: 10,
marks: ["foo", "bar"],
})
Which is best practice?