You can see the problem next:
// @flow
import React from 'react';
type Props = {
title: string,
text?: string, // eslint error 'react/require-default-props'
};
export const TestComp1 = ({ title, text = '' }: Props) => (
<button title={title}>{text}</button>
);
Use defaultProps, not default values.
what if i don't wanna?
that should be an option
That's always an option - disable the rule.