diff --git a/.gitignore b/.gitignore index 3557f05..beab98a 100644 --- a/.gitignore +++ b/.gitignore @@ -38,3 +38,6 @@ jspm_packages .node_repl_history .DS_Store + +# webStorm config file +.idea \ No newline at end of file diff --git a/chapter-02/controlpanel_with_summary/package.json b/chapter-02/controlpanel_with_summary/package.json index 1557900..dc640c3 100644 --- a/chapter-02/controlpanel_with_summary/package.json +++ b/chapter-02/controlpanel_with_summary/package.json @@ -47,6 +47,7 @@ "whatwg-fetch": "1.0.0" }, "dependencies": { + "prop-types": "^15.5.10", "react": "^15.4.1", "react-dom": "^15.4.1" }, @@ -79,4 +80,4 @@ "eslintConfig": { "extends": "react-app" } -} \ No newline at end of file +} diff --git a/chapter-02/controlpanel_with_summary/src/Counter.js b/chapter-02/controlpanel_with_summary/src/Counter.js index 63726fa..b782a75 100644 --- a/chapter-02/controlpanel_with_summary/src/Counter.js +++ b/chapter-02/controlpanel_with_summary/src/Counter.js @@ -1,4 +1,5 @@ -import React, { Component, PropTypes } from 'react'; +import React, { Component } from 'react'; +import PropTypes from 'prop-types'; const buttonStyle = { margin: '10px'