Syntax error in ImageEditingExample.js for using 'type' for Objects
I am getting Syntax error for the following objects. I do hope they are objects.
type ImageOffset = {
x: 100;
y: 100;
};
type ImageSize = {
width: 100;
height: 100;
};
type TransformData = {
offset: ImageOffset;
size: ImageSize;
}
How do I fix this syntax error?
Hey vinu123, thanks for reporting this issue!
React Native, as you've probably heard, is getting really popular and truth is we're getting a bit overwhelmed by the activity surrounding it. There are just too many issues for us to manage properly.
- If you don't know how to do something or not sure whether some behavior is expected or a bug, please ask on StackOverflow with the tag
react-nativeor for more real time interactions, ask on Discord in the #react-native channel. - If this is a feature request or a bug that you would like to be fixed, please report it on Product Pains. It has a ranking feature that lets us focus on the most important issues the community is experiencing.
- We welcome clear issues and PRs that are ready for in-depth discussion. Please provide screenshots where appropriate and always mention the version of React Native you're using. Thank you for your contributions!
They are Flow type declarations. Babel supports stripping them out. Where are you getting syntax errors?
@facebook-github-bot answered
Closing this issue as @satya164 says the question asked has been answered. Please help us by asking questions on StackOverflow. StackOverflow is amazing for Q&A: it has a reputation system, voting, the ability to mark a question as answered. Because of the reputation system it is likely the community will see and answer your question there. This also helps us use the GitHub bug tracker for bugs only.