From dfe72d73ca1fb9f4e9f2360f5eed5af03ca21c99 Mon Sep 17 00:00:00 2001 From: Andrew Vernon Date: Wed, 10 May 2017 15:46:59 +1200 Subject: [PATCH] Fix React 15.5 deprecation warnings --- modules/PointTarget.js | 3 ++- modules/__tests__/PointTarget-test.js | 2 +- package.json | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/PointTarget.js b/modules/PointTarget.js index 8da6a2f..30b0de6 100644 --- a/modules/PointTarget.js +++ b/modules/PointTarget.js @@ -1,4 +1,5 @@ -import React, { PropTypes } from 'react' +import React from 'react' +import PropTypes from 'prop-types' const touchX = (event) => event.touches[0].clientX diff --git a/modules/__tests__/PointTarget-test.js b/modules/__tests__/PointTarget-test.js index 9b5e472..ebdb6db 100644 --- a/modules/__tests__/PointTarget-test.js +++ b/modules/__tests__/PointTarget-test.js @@ -1,7 +1,7 @@ import expect from 'expect' import React from 'react' import { render } from 'react-dom' -import { Simulate } from 'react-addons-test-utils' +import { Simulate } from 'react-dom/test-utils' import PointTarget from '../PointTarget' const touch = (clientX, clientY) => ({ diff --git a/package.json b/package.json index 6d7e9aa..e64d718 100644 --- a/package.json +++ b/package.json @@ -47,6 +47,7 @@ "karma-webpack": "^2.0.1", "mocha": "^3.0.0", "pretty-bytes": "^4.0.2", + "prop-types": "^15.5.9", "react": "^15.3.0", "react-addons-test-utils": "^15.3.0", "react-dom": "^15.3.0",