diff --git a/.changeset/hip-toys-learn.md b/.changeset/hip-toys-learn.md new file mode 100644 index 00000000..59492e4a --- /dev/null +++ b/.changeset/hip-toys-learn.md @@ -0,0 +1,5 @@ +--- +"@10up/eslint-config": minor +--- + +Update eslint rule for typescript to use default arguments for default props. diff --git a/packages/eslint-config/config/react.js b/packages/eslint-config/config/react.js index 68ec3ff4..5803ff6c 100644 --- a/packages/eslint-config/config/react.js +++ b/packages/eslint-config/config/react.js @@ -34,6 +34,8 @@ module.exports = { files: ['*.ts', '*.tsx'], rules: { 'react/prop-types': 0, + 'react/require-default-props': ['error', { functions: 'defaultArguments' }], + 'jsdoc/require-returns-type': 'off', }, }, ],