text: import { connect } from 'react-redux'
  import { visibilityFilter } from '../actions'
  import Link from '../components/Link'
  
  const  mapStateToProps = (state, ownProps) => {
    return {
      active: ownProps.filter === state.visibilityFilter
    }
  }
  
  const mapDispatchToProps = (dispatch, ownProps) => {
    return {
      onClick: () => {
        dispatch(visibilityFilter(ownProps.filter))
      }
    }
  }
  
  const FilterLink = connect(mapStateToProps, mapDispatchToProps)(Link)
  
  export default FilterLink
  