Skip to content

Commit 2a4e626

Browse files
mastrauckasroylee0704
authored andcommitted
Moving react to v15.5.4 to remove warning 'Warning: Accessing PropTypes via the main React package is deprecated. Use the prop-types package from npm instead.'. (#107)
1 parent 1a9a160 commit 2a4e626

File tree

8 files changed

+45
-30
lines changed

8 files changed

+45
-30
lines changed

doc/app/components/box/index.jsx

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
1-
import React, {PropTypes} from 'react';
2-
import {Col} from 'react-flexbox-grid';
1+
import React from 'react';
2+
import PropTypes from 'prop-types';
3+
import { Col } from 'react-flexbox-grid';
34
import box from './style';
45

56
const Box = (props) => {
67
return (
78
<Col {...props}>
8-
<div className = {box[props.type || 'box']}>
9-
{props.children}
10-
</div>
9+
<div className={box[props.type || 'box']}>
10+
{props.children}
11+
</div>
1112
</Col>
1213
);
1314
};

doc/app/components/button/index.jsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import React, {PropTypes} from 'react';
1+
import React from 'react';
2+
import PropTypes from 'prop-types';
23
import style from './style';
34

45
const Button = (props) => {

doc/app/components/section/index.jsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
import React, {PropTypes} from 'react';
1+
import React from 'react';
2+
import PropTypes from 'prop-types';
23
import style from './style';
34

45
const Section = (props) => {
56
return (
6-
<section className = {style.section}>
7+
<section className={style.section}>
78
<h2>{props.title}</h2>
89
<p>{props.description}</p>
910
{props.children}

package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@
2323
"react-component"
2424
],
2525
"dependencies": {
26-
"flexboxgrid": "^6.3.0"
26+
"flexboxgrid": "^6.3.0",
27+
"prop-types": "^15.5.8"
2728
},
2829
"devDependencies": {
2930
"@types/react": "*",
@@ -60,9 +61,9 @@
6061
"node-sass": "^3.4.2",
6162
"phantomjs": "^1.9.19",
6263
"postcss-loader": "^0.7.0",
63-
"react": "^15.2.0",
64-
"react-addons-test-utils": "^15.2.0",
65-
"react-dom": "^15.2.0",
64+
"react": "^15.5.4",
65+
"react-addons-test-utils": "^15.5.1",
66+
"react-dom": "^15.5.4",
6667
"react-hot-loader": "^1.3.0",
6768
"redbox-react": "^1.1.1",
6869
"rimraf": "^2.4.4",
@@ -87,7 +88,7 @@
8788
},
8889
"license": "MIT",
8990
"peerDependencies": {
90-
"react": "^0.14.3 || ^15.0.0"
91+
"react": "^0.14.3 || ^15.5.4"
9192
},
9293
"types": "react-flexbox-grid.d.ts"
9394
}

src/components/Col.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import React, { PropTypes } from 'react';
1+
import React from 'react';
2+
import PropTypes from 'prop-types';
23
import createProps from '../createProps';
34
import getClass from '../classNames';
45
import { ColumnSizeType, ViewportSizeType } from '../types';

src/components/Grid.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import React, { PropTypes } from 'react';
1+
import React from 'react';
2+
import PropTypes from 'prop-types';
23
import createProps from '../createProps';
34
import getClass from '../classNames';
45

src/components/Row.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import getClass from '../classNames';
2-
import React, { PropTypes } from 'react';
2+
import React from 'react';
3+
import PropTypes from 'prop-types';
34
import createProps from '../createProps';
45
import { ViewportSizeType } from '../types';
56

yarn.lock

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2058,9 +2058,9 @@ fastparse@^1.1.1:
20582058
version "1.1.1"
20592059
resolved "https://registry.yarnpkg.com/fastparse/-/fastparse-1.1.1.tgz#d1e2643b38a94d7583b479060e6c4affc94071f8"
20602060

2061-
fbjs@^0.8.1, fbjs@^0.8.4:
2062-
version "0.8.9"
2063-
resolved "https://registry.yarnpkg.com/fbjs/-/fbjs-0.8.9.tgz#180247fbd347dcc9004517b904f865400a0c8f14"
2061+
fbjs@^0.8.4, fbjs@^0.8.9:
2062+
version "0.8.12"
2063+
resolved "https://registry.yarnpkg.com/fbjs/-/fbjs-0.8.12.tgz#10b5d92f76d45575fd63a217d4ea02bea2f8ed04"
20642064
dependencies:
20652065
core-js "^1.0.0"
20662066
isomorphic-fetch "^2.1.1"
@@ -4220,6 +4220,12 @@ promise@^7.1.1:
42204220
dependencies:
42214221
asap "~2.0.3"
42224222

4223+
prop-types@^15.5.7, prop-types@^15.5.8, prop-types@~15.5.7:
4224+
version "15.5.8"
4225+
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.5.8.tgz#6b7b2e141083be38c8595aa51fc55775c7199394"
4226+
dependencies:
4227+
fbjs "^0.8.9"
4228+
42234229
proxy-addr@~1.1.3:
42244230
version "1.1.3"
42254231
resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-1.1.3.tgz#dc97502f5722e888467b3fa2297a7b1ff47df074"
@@ -4306,9 +4312,9 @@ rc@~1.1.6:
43064312
minimist "^1.2.0"
43074313
strip-json-comments "~1.0.4"
43084314

4309-
react-addons-test-utils@^15.2.0:
4310-
version "15.4.2"
4311-
resolved "https://registry.yarnpkg.com/react-addons-test-utils/-/react-addons-test-utils-15.4.2.tgz#93bcaa718fcae7360d42e8fb1c09756cc36302a2"
4315+
react-addons-test-utils@^15.5.1:
4316+
version "15.5.1"
4317+
resolved "https://registry.yarnpkg.com/react-addons-test-utils/-/react-addons-test-utils-15.5.1.tgz#e0d258cda2a122ad0dff69f838260d0c3958f5f7"
43124318
dependencies:
43134319
fbjs "^0.8.4"
43144320
object-assign "^4.1.0"
@@ -4317,13 +4323,14 @@ react-deep-force-update@^1.0.0:
43174323
version "1.0.1"
43184324
resolved "https://registry.yarnpkg.com/react-deep-force-update/-/react-deep-force-update-1.0.1.tgz#f911b5be1d2a6fe387507dd6e9a767aa2924b4c7"
43194325

4320-
react-dom@^15.2.0:
4321-
version "15.4.2"
4322-
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.4.2.tgz#015363f05b0a1fd52ae9efdd3a0060d90695208f"
4326+
react-dom@^15.5.4:
4327+
version "15.5.4"
4328+
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.5.4.tgz#ba0c28786fd52ed7e4f2135fe0288d462aef93da"
43234329
dependencies:
4324-
fbjs "^0.8.1"
4330+
fbjs "^0.8.9"
43254331
loose-envify "^1.1.0"
43264332
object-assign "^4.1.0"
4333+
prop-types "~15.5.7"
43274334

43284335
react-hot-api@^0.4.5:
43294336
version "0.4.7"
@@ -4354,13 +4361,14 @@ react-transform-hmr@^1.0.3:
43544361
global "^4.3.0"
43554362
react-proxy "^1.1.7"
43564363

4357-
react@^15.2.0:
4358-
version "15.4.2"
4359-
resolved "https://registry.yarnpkg.com/react/-/react-15.4.2.tgz#41f7991b26185392ba9bae96c8889e7e018397ef"
4364+
react@^15.5.4:
4365+
version "15.5.4"
4366+
resolved "https://registry.yarnpkg.com/react/-/react-15.5.4.tgz#fa83eb01506ab237cdc1c8c3b1cea8de012bf047"
43604367
dependencies:
4361-
fbjs "^0.8.4"
4368+
fbjs "^0.8.9"
43624369
loose-envify "^1.1.0"
43634370
object-assign "^4.1.0"
4371+
prop-types "^15.5.7"
43644372

43654373
read-pkg-up@^1.0.1:
43664374
version "1.0.1"

0 commit comments

Comments
 (0)