What does {...this.props} mean in this code?
{...this.props}
Answer
The {...variable} syntax is called "spread attributes".
{...variable}
What this does is, basically, it takes every property of this.props (or any other passed variable) and applies them to the element.
this.props
Example:
props = {className: 'big', href: 'http://example.com'};// the above line is equal to the following
I want to output an inline jpg image as a base64 encoded string, however when I do this : $contents = file_get_contents($filename); print ...
No comments:
Post a Comment