Skip to content
This repository was archived by the owner on Feb 6, 2023. It is now read-only.

Commit 280d242

Browse files
samwgoldmanfacebook-github-bot
authored andcommitted
Add return type annotation to addEmojiInput
Summary: Flow does not infer generics, so generic functions should have annotated return types. This will become an error in the next Flow version. Note that this uncovered a bunch of errors, which I mostly fixed. I suppressed a few that would require code changes. Reviewed By: nmote Differential Revision: D10419507 fbshipit-source-id: 84b8f33f3c8fe272b18e35e838a0ebf7bdbaa6ff
1 parent 7df9eb9 commit 280d242

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/component/base/DraftEditorProps.js

+1
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ export type DraftEditorProps = {
4747
// styling and formatting when re-applying styles.
4848
editorKey?: string,
4949

50+
// $FlowFixMe in practice people pass other renderable things here
5051
placeholder?: string,
5152

5253
// Specify whether text alignment should be forced in a direction

src/model/constants/DraftHandleValue.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919
* A type that allows us to avoid returning boolean values
2020
* to indicate whether an event was handled or not.
2121
*/
22-
export type DraftHandleValue = 'handled' | 'not-handled';
22+
export type DraftHandleValue = 'handled' | 'not-handled' | boolean;

0 commit comments

Comments
 (0)