Chart.js legend callbacks: unresolved dataset visibility toggle timing
Goal Determine how the Chart.js legend onClick handler updates the dataset.hidden flag relative to a custom onClick callback across major releases. Constraints Chart.js 2.x updates the flag before the callback, while 3.x and 4.x update it after. The library documentation lists the callback signature but omits the order of operations, leaving developers uncer