From c6bb97894784c4c4e32c46d4f5e006f2f3283fad Mon Sep 17 00:00:00 2001 From: Chris Bobbe Date: Fri, 27 Aug 2021 16:06:16 -0700 Subject: [PATCH] Centerer types [nfc]: Annotate for types-first. We're not totally satisfied with how we annotate `defaultProps` (see f801c9779), but it works, and we'd like to remove `Centerer` anyway; issue #4868 is in progress toward that. Related: #4907 --- src/common/Centerer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/Centerer.js b/src/common/Centerer.js index 8aae2f82212..17aa0300b3f 100644 --- a/src/common/Centerer.js +++ b/src/common/Centerer.js @@ -34,11 +34,11 @@ type Props = $ReadOnly<{| * @prop [padding] - Specifies if the components should be padded. */ export default class Centerer extends PureComponent { - static defaultProps = { + static defaultProps: {| padding: boolean |} = { padding: false, }; - render() { + render(): Node { const { children, padding, style } = this.props; return (