Sha256: acc6083d739e73a1be658c15c7fe8d2a5bc7569c1521acfd6704c0918108ce75
Contents?: true
Size: 361 Bytes
Versions: 24
Compression:
Stored size: 361 Bytes
Contents
import React from 'react'; // TODO: extract to core const withProtectedView = ( ProtectedComponent, ProtectionComponent, protectionFn, extraProtectionProps = {} ) => props => protectionFn(props) ? ( <ProtectedComponent {...props} /> ) : ( <ProtectionComponent {...props} {...extraProtectionProps} /> ); export default withProtectedView;
Version data entries
24 entries across 24 versions & 1 rubygems