aperitif-editor icon indicating copy to clipboard operation
aperitif-editor copied to clipboard

[Feature] Nested prop destructuring.

Open danielrob opened this issue 6 years ago • 0 comments

Currently, props that are objects cannot be destructured in the list of component props. Desired e.g. the ability to interact with user.profileImageUrl without first creating a <User {...user} /> component intermediary.

Perhaps a {} option next to object props that allows you to destructure them further.

const Component = ({
  item,
  user, 
  user: { profileImageUrl },
}) => ....

danielrob avatar Jul 11 '18 08:07 danielrob