Fluentui: React v15.5 claims deprecation warning

Created on 8 May 2017  路  3Comments  路  Source: microsoft/fluentui

Bug Report

  • office-ui-fabric-react: 2.17.0
  • react: 15.5.4

Priorities and help requested (not applicable if asking question):

Are you willing to submit a PR to fix? Yes

Requested priority: Normal

Describe the issue:

By React v15.5, React.PropTypes is deprecated.

Latest office-ui-fabric-react calls it directly, so we encounter the deprecation message like below.

Warning: Accessing PropTypes via the main React package is deprecated. Use the prop-types package from npm instead.

Type

Most helpful comment

I've found react-addons-test-utils is also deprecated, it moved into react-dom/test-utils.

We have to resolve both finally, but probably we can try them separately.

I'll try the following steps.

  1. switch to prop-types with keeping React v15.4
  2. update React to v15.5, and replace react-addons-test-utils

All 3 comments

I'm not sure we can resolve this without taking a hard dependency on 15.5.4 which may break a lot of people.

From my understanding it should be backwards compatible if you included the prop-types package and replaced references React.PropTypes with https://github.com/reactjs/prop-types#compatibility

I'm happy to do a PR to fix this issue as well

I've found react-addons-test-utils is also deprecated, it moved into react-dom/test-utils.

We have to resolve both finally, but probably we can try them separately.

I'll try the following steps.

  1. switch to prop-types with keeping React v15.4
  2. update React to v15.5, and replace react-addons-test-utils
Was this page helpful?
0 / 5 - 0 ratings