diff --git a/package.json b/package.json index 900b4f1..daa5ddb 100644 --- a/package.json +++ b/package.json @@ -8,8 +8,9 @@ "prepublish": "npm run build" }, "dependencies": { - "react": "^15.3.2", - "react-dom": "^15.3.2" + "react": "^15.6.0", + "react-dom": "^15.6.0", + "prop-types": "^15.5.10", }, "keywords": [ "react", diff --git a/src/ResizableComponent.jsx b/src/ResizableComponent.jsx index 58718db..e66c967 100644 --- a/src/ResizableComponent.jsx +++ b/src/ResizableComponent.jsx @@ -1,5 +1,6 @@ var React = require('react'); var ReactDOM = require('react-dom'); +var PropTypes = require('prop-types'); var ResizableComponent = React.createClass({ getInitialState: function() { @@ -39,26 +40,26 @@ var ResizableComponent = React.createClass({ }, propTypes: { - children: React.PropTypes.element.isRequired, - direction: React.PropTypes.oneOf(['s', 'e', 'se']), + children: PropTypes.element.isRequired, + direction: PropTypes.oneOf(['s', 'e', 'se']), // Dimensions - width: React.PropTypes.number, - height: React.PropTypes.number, + width: PropTypes.number, + height: PropTypes.number, // Styling - className: React.PropTypes.string, - style: React.PropTypes.object, - ghostCssStyles: React.PropTypes.object, + className: PropTypes.string, + style: PropTypes.object, + ghostCssStyles: PropTypes.object, // Callbacks - onStartResize: React.PropTypes.func, - onStopResize: React.PropTypes.func, - onEachStep: React.PropTypes.func, - onDuringResize: React.PropTypes.func, + onStartResize: PropTypes.func, + onStopResize: PropTypes.func, + onEachStep: PropTypes.func, + onDuringResize: PropTypes.func, // Other options - options: React.PropTypes.object + options: PropTypes.object }, getDefaultProps: function() { @@ -313,4 +314,4 @@ var ResizableComponent = React.createClass({ } }); -module.exports = ResizableComponent; \ No newline at end of file +module.exports = ResizableComponent;