Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ViewPropTypes warns but documentation missing/link broken #13999

Closed
scarlac opened this issue May 16, 2017 · 2 comments
Closed

ViewPropTypes warns but documentation missing/link broken #13999

scarlac opened this issue May 16, 2017 · 2 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@scarlac
Copy link
Contributor

scarlac commented May 16, 2017

Description

Attempted to use a library that uses View.propTypes. Got a warning: Warning: View.propTypes has been deprecated and will be removed in a future version of ReactNative. Use ViewPropTypes instead yet looking up ViewPropTypes yields nothing on the official site and Google only contains results about issues on other projects.

Reproduction Steps and Sample Code

List all the steps required to reproduce the issue you're reporting. These steps should be clear and concise.

An example of your code is REQUIRED

export default class SomeClass extends React.PureComponent {
  static propTypes = {
    style: View.propTypes.style,
  }
  // ...
}

Documentation for View is currently linking to /viewproptypes.html#props which just forwards to "Getting Started" instead.

Solution

Provide at documentation page for ViewPropTypes that list how to use it. I eventually found (by browsing the RN code base) that you can import ViewPropTypes from 'react-native' package like this:

import {Text, View, ViewPropTypes} from 'react-native';

Additional Information

  • React Native version: react-native@0.44.0
  • Platform: iOS (and likely Android - untested)
  • Development Operating System: macOS 10.12.4 (16E195)
  • Dev tools: Xcode, iOS Simulator with 10.3 SDK/iPhone 6.
@hramos
Copy link
Contributor

hramos commented Jul 20, 2017

Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we're automatically closing issues after a period of inactivity. Please do not take it personally!

If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:

  • Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
  • If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
  • Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.

If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.

@geirman
Copy link
Contributor

geirman commented Jan 5, 2018

I think this should be reopened

@facebook facebook locked as resolved and limited conversation to collaborators Jul 20, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

4 participants