// @flow
/* eslint-disable import/no-extraneous-dependencies */
import React from 'react'
const withDefault = (propCheck: Function, DefaultCmp: Function) => (BaseCmp: Function) => (
props: Object,
) => {
if (propCheck(props)) {
return
}
return DefaultCmp ? : null
}
export default withDefault