import PropTypes from 'prop-types'; import React from 'react'; import { Link } from 'react-router'; import InlineSVG from 'react-inlinesvg'; import check from '../../../../images/check.svg'; const checkIcon = ( ); const CollectionItem = ({ inCollection, collection, onSelect }) => (
  • {inCollection && checkIcon}
    View
  • ); CollectionItem.propTypes = { inCollection: PropTypes.bool.isRequired, onSelect: PropTypes.func.isRequired, collection: PropTypes.shape({ name: PropTypes.string, }).isRequired, }; export default CollectionItem;