From e0ead6910032b4afab44caac01c1b013dc6c06aa Mon Sep 17 00:00:00 2001 From: perqa Date: Thu, 4 Feb 2016 14:41:03 +0100 Subject: [PATCH] Update README.md I could not get the Video component to work by following the provided example. I kept getting an error message saying "React.createElement: type should not be null, undefined, boolean, or number.". When I changed the way I include the component, it started working. It might be related to recent versions of react-native, not sure. You're welcome to modify the suggested text if you like. Thanks for a great piece of work! --- README.md | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4996d34e..a7677fe7 100644 --- a/README.md +++ b/README.md @@ -89,7 +89,7 @@ Seeks the video to the specified time (in seconds). Access using a ref to the co ## Examples -- See an [Example integration][1] in `react-native-login`. +- See an [Example integration][1] in `react-native-login`*. - Try the included [VideoPlayer example][2] yourself: ```sh @@ -102,6 +102,15 @@ Seeks the video to the specified time (in seconds). Access using a ref to the co Then `Cmd+R` to start the React Packager, build and run the project in the simulator. +*The example from `react-native-login` does not seem to work in some cases. Try replacing +``` +var Video = require('react-native-video'); +``` +by +``` +import Video from 'react-native-video'; +``` + ## TODOS