You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One thing that doesn't quite feel right is how so many new objects are created during the render pass when using a context object:
// Computes the data to pass into the data join from component invocation arguments.functiondataArray(data,context){data=Array.isArray(data) ? data : [data];returncontext ? data.map(d=>Object.assign(Object.create(context),d)) : data;}
What if instead of creating new objects and shallow merging each datum with the context object, we split up the API such that the lifecycle hooks refer to the context object explicitly, rather than having stuff from the context object implicitly end up on d?
One thing that doesn't quite feel right is how so many new objects are created during the render pass when using a context object:
What if instead of creating new objects and shallow merging each datum with the context object, we split up the API such that the lifecycle hooks refer to the context object explicitly, rather than having stuff from the context object implicitly end up on
d
?Before:
After:
Pros:
Cons:
The text was updated successfully, but these errors were encountered: