-
Notifications
You must be signed in to change notification settings - Fork 73
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
Property definition with reusable propTypes #32
Labels
documentation
Improvements or additions to documentation
Comments
Here is how you can reuse PropTypes:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
I'm trying the following:
I have some propTypes I want to define central and reuse it in many components.
There fore I have create a file "baseTypes"
Now I want to use this definition in many other components like this:
How ever, only the 2 in the file defined properties are shown in the props panel. alignSelf (defined in another file) is not show.
How are you reading the props definitions?
By parsing the source code or by using
Component.propTypes
?Looks for my like toe first one is true.
There reason why I have this issue is, that I using a UI Framework. They already have created all this propTypes definitions and I just want to reuse it instead of copy and paste it to my source code.
But for any reason it don't works as expected.
The text was updated successfully, but these errors were encountered: