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

Where did the location/locationShape PropType go in v4? #4506

Closed
mark0978 opened this issue Feb 9, 2017 · 2 comments
Closed

Where did the location/locationShape PropType go in v4? #4506

mark0978 opened this issue Feb 9, 2017 · 2 comments

Comments

@mark0978
Copy link

mark0978 commented Feb 9, 2017

This was present as recently as alpha-6, but in the current beta-5 appears to be gone.

node_modules/react-router/PropTypes.js:23:var location = exports.location = _react.PropTypes.shape({

I find evidence that maybe it should be there in:

./modules/index.js:16:export { locationShape, routerShape } from './PropTypes'
./modules/PropTypes.js:15:export const locationShape = shape({

But it doesn't show up in the installed product.

I'd be happy to work on a PR to fix it unless this is by design.

@pshrmn
Copy link
Contributor

pshrmn commented Feb 9, 2017

This was intentional. See #4419.

@pshrmn pshrmn closed this as completed Feb 9, 2017
@simon-rad
Copy link

@mark0978 Hello, I'm using strict eslint rules for prop-types, so we had to define all the shapes.
I have created a package just for props, so those shapes are not duplicated all over the projects.
Thought maybe it would be helpful for you also.
https://www.npmjs.com/package/react-router-props

@lock lock bot locked as resolved and limited conversation to collaborators Jan 19, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants