From 0b750b7a047eab6d83f5630a86613df934e214d8 Mon Sep 17 00:00:00 2001 From: Ricardo Reis Date: Wed, 17 May 2017 03:28:19 +0100 Subject: [PATCH] Fix prop-types deprecation warning with react >= 15.5 (#9) --- package.json | 3 ++- src/scrollbar.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 186b1da..b883cf3 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,8 @@ "react-dom": ">=0.14.0" }, "dependencies": { - "perfect-scrollbar": "^0.6.12" + "perfect-scrollbar": "^0.6.12", + "prop-types": "^15.5" }, "devDependencies": { "autoprefixer": "^6.6.1", diff --git a/src/scrollbar.js b/src/scrollbar.js index 376dd51..8a71d85 100644 --- a/src/scrollbar.js +++ b/src/scrollbar.js @@ -1,4 +1,5 @@ -import React, { Component, PropTypes } from 'react'; +import React, { Component } from 'react'; +import { PropTypes } from 'prop-types'; import ps from 'perfect-scrollbar'; const handlerNameByEvent = {