fbredius/storybook

View on GitHub
addons/docs/src/frameworks/react/__testfixtures__/9465-ts-type-props/input.tsx

Summary

Maintainability
A
0 mins
Test Coverage
import React from 'react';

type Props = React.ButtonHTMLAttributes<HTMLButtonElement> & {
  disabled?: boolean;
};

const Component = ({ disabled = false, children }: Props) => (
  // eslint-disable-next-line react/button-has-type
  <button disabled={disabled}>{children}</button>
);

export const component = Component;