Skip to content

Commit 7b2f4d5

Browse files
committed
Fix Flow 0.28 errors with parameterized types
1 parent 231afba commit 7b2f4d5

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/Draggable.es6

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ type DraggableState = {
2121
type ConstructorProps = {
2222
position: { x: number, y: number },
2323
defaultPosition: { x: number, y: number }
24-
}
24+
};
2525

2626
//
2727
// Define <Draggable>
@@ -288,7 +288,7 @@ export default class Draggable extends React.Component {
288288
this.setState(newState);
289289
};
290290

291-
render(): React.Element {
291+
render(): React.Element<any> {
292292
let style = {}, svgTransform = null;
293293

294294
// If this is controlled, we don't want to move it - unless it's dragging.

lib/DraggableCore.es6

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ export default class DraggableCore extends React.Component {
334334
return this.handleDragStop(e);
335335
};
336336

337-
render(): React.Element {
337+
render(): React.Element<any> {
338338
// Reuse the child provided
339339
// This makes it flexible to use whatever element is wanted (div, ul, etc)
340340
return React.cloneElement(React.Children.only(this.props.children), {

0 commit comments

Comments
 (0)