Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Youtube in React: Rating component skeleton
import React from 'react';
import './Rating.scss';
import {Icon, Progress} from "semantic-ui-react";
export function Rating() {
let progress = null;
if (props.likeCount && props.dislikeCount) {
const percent = 100 * (props.likeCount / (props.likeCount + props.dislikeCount));
progress = <Progress className='progress' percent={percent} size='tiny'/>;
/* return (...) */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment