Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

explicitly importing react types to avoid deprecation warnings #184

Merged
merged 1 commit into from Nov 20, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/view/drag-drop-context/drag-drop-context.jsx
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import React, { type Node } from 'react';
import PropTypes from 'prop-types';
import createStore from '../../state/create-store';
import fireHooks from '../../state/fire-hooks';
Expand All @@ -12,7 +12,7 @@ import { storeKey } from '../context-keys';

type Props = {|
...Hooks,
children: ?React.Node,
children: ?Node,
|}

type Context = {
Expand Down
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import type { Node } from 'react';
import {
publishDraggableDimension,
} from '../../state/action-creators';
Expand All @@ -22,7 +22,7 @@ export type OwnProps = {|
droppableId: DroppableId,
type: TypeId,
targetRef: ?HTMLElement,
children: React.Node,
children: Node,
|}

export type Props = {|
Expand Down
6 changes: 3 additions & 3 deletions src/view/draggable/draggable-types.js
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import type { Node } from 'react';
import type {
DraggableId,
DraggableDimension,
Expand Down Expand Up @@ -99,7 +99,7 @@ export type Provided = {|
innerRef: (?HTMLElement) => void,
draggableStyle: ?DraggableStyle,
dragHandleProps: ?DragHandleProvided,
placeholder: ?React.Node,
placeholder: ?Node,
|}

export type StateSnapshot = {|
Expand Down Expand Up @@ -133,7 +133,7 @@ export type MapProps = {|

export type OwnProps = {|
draggableId: DraggableId,
children: (Provided, StateSnapshot) => ?React.Node,
children: (Provided, StateSnapshot) => ?Node,
type: TypeId,
isDragDisabled: boolean,
|}
Expand Down
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import type { Node } from 'react';
import {
publishDroppableDimension,
updateDroppableDimensionIsEnabled,
Expand Down Expand Up @@ -28,7 +28,7 @@ export type OwnProps = {|
type: TypeId,
targetRef: ?HTMLElement,
ignoreContainerClipping: boolean,
children: React.Node,
children: Node,
|}

export type Props = {|
Expand Down
6 changes: 3 additions & 3 deletions src/view/droppable/droppable-types.js
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import type { Node } from 'react';
import type {
DroppableId,
TypeId,
Expand All @@ -13,7 +13,7 @@ export type Placeholder = {|

export type Provided = {|
innerRef: (?HTMLElement) => void,
placeholder: ?React.Node,
placeholder: ?Node,
|}

export type StateSnapshot = {|
Expand All @@ -29,7 +29,7 @@ export type MapProps = {|
|}

export type OwnProps = {|
children: (Provided, StateSnapshot) => ?React.Node,
children: (Provided, StateSnapshot) => ?Node,
droppableId: DroppableId,
type: TypeId,
isDropDisabled: boolean,
Expand Down
4 changes: 2 additions & 2 deletions src/view/moveable/moveable-types.js
@@ -1,5 +1,5 @@
// @flow
import * as React from 'react';
import type { Node } from 'react';
import type { Position } from '../../types';

export type Speed = 'INSTANT' | 'STANDARD' | 'FAST';
Expand All @@ -12,7 +12,7 @@ export type Props = {|
speed: Speed,
destination: Position,
onMoveEnd: () => void,
children: (Style) => React.Node,
children: (Style) => Node,
|}

export type DefaultProps = {|
Expand Down