When instantiating props in the render method of a component, does that have a performance hit (albeit small)? My theory is that on every render this variable is re-created in memory. Over many components this could add to significant performance implications?
render() {
const { title, pages, pictures, cover } = this.props;
return (
<Book
title={title}
pages={pages}
pictures={pictures}
cover={cover}
/>
);
}
// VS the follow
render() {
return (
<Book
title={this.props.title}
pages={this.props.pages}
pictures={this.props.pictures}
cover={this.props.cover}
/>
);
}