How to use the recompact.withProps function in recompact

To help you get started, we’ve selected a few recompact examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github rainbow-me / rainbow / src / hoc / withUniqueTokens.js View on Github external
export default Component =>
  compose(
    connect(mapStateToProps),
    withProps(sendableUniqueTokens)
  )(Component);
github rainbow-me / rainbow / src / components / layout / Row.js View on Github external
import { compose, setDisplayName, withProps } from 'recompact';
import Flex from './Flex';

export default compose(
  setDisplayName('Row'),
  withProps({ direction: 'row' }),
)(Flex);
github rainbow-me / rainbow / src / components / layout / RowWithDividers.js View on Github external
import { compose, setDisplayName, withProps } from 'recompact';
import LayoutWithDividers from './LayoutWithDividers';

export default compose(
  setDisplayName('RowWithDividers'),
  withProps(({ dividerProps }) => ({
    direction: 'row',
    dividerProps: {
      horizontal: false,
      ...dividerProps,
    },
  }))
)(LayoutWithDividers);
github rainbow-me / rainbow / src / components / layout / Centered.js View on Github external
import { compose, setDisplayName, withProps } from 'recompact';
import Flex from './Flex';

export default compose(
  setDisplayName('Centered'),
  withProps({ align: 'center', justify: 'center' }),
)(Flex);

recompact

A set of React high order components based on Rx.

MIT
Latest version published 6 years ago

Package Health Score

45 / 100
Full package analysis