utils#NOOP TypeScript Examples

The following examples show how to use utils#NOOP. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Button.tsx    From substrate-api-explorer with Apache License 2.0 6 votes vote down vote up
Button = ({
  fluid,
  type,
  theme = 'primary',
  disabled,
  condensed,
  text,
  onClick,
  className = '',
  style
}: Props) => (
  <S.Wrapper
    fluid={fluid}
    type={type}
    theme={ButtonThemes.includes(theme) ? theme : 'primary'}
    disabled={disabled}
    condensed={condensed}
    onClick={onClick || NOOP}
    className={className}
    style={style}
  >
    {text}
  </S.Wrapper>
)