Created
April 25, 2020 18:22
-
-
Save mohnatus/ca950ca99cbac20cc936c04f0b62382d to your computer and use it in GitHub Desktop.
Skeleton screens (React)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
const Card = ({ item, channel }) => { | |
return ( | |
<li className="card"> | |
<a | |
href={`https://www.youtube.com/watch?v=${item.id}`} | |
target="\_blank" | |
rel="noopener noreferrer" | |
className="card-link" | |
> | |
<img src={item.image} alt={item.title} className="card-image" /> | |
<img src={item.image} alt={item.title} className="channel-image" /> | |
<h4 className="card-title">{item.title}</h4> | |
<p className="card-channel"> | |
<i>{channel}</i> | |
</p> | |
<div className="card-metrics"> | |
{item.views} • {item.published} | |
</div> | |
</a> | |
</li> | |
); | |
}; | |
export default Card; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment