{"size": 787, "ext": "js", "max_stars_repo_path": "src/components/Card.js", "max_stars_repo_name": "shweshi/unlist", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/components/Card.js", "max_issues_repo_name": "shweshi/unlist", "max_issues_repo_issues_event_min_datetime": "2021-07-06T08:50:59.000Z", "max_issues_repo_issues_event_max_datetime": "2021-07-06T08:50:59.000Z", "max_forks_repo_path": "src/components/Card.js", "max_forks_repo_name": "shweshi/unlist", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 1, "max_forks_count": null, "avg_line_length": 21.8611111111, "max_line_length": 61, "alphanum_fraction": 0.457433291}
import React, { Component } from 'react'
import { Link } from 'react-router-dom';

class Card extends Component {
  constructor(props) {
    super(props)
    this.state = this.props;
  }

  render() {
    const cards = this.state.listsData.map((list, index) => {
      return (
        <div className="col-md-4">
          <Link to={{
            pathname: "/details",
            state: {
              list,
              about: {
                title: list.title,
                description: list.description
              }
            }
          }}>
            <div className="card card-1">
              <h3>{list.title}</h3>
              <p>{list.description}</p>
            </div>
          </Link>
        </div>
      )
    })
    return cards;
  }
}

export default Card