Make the __DEV__ argument check more robust
Make the __DEV__ argument check more robust

Summary: JSON.stringify will convert a function to null, but folly::dynamic in the native code can't represent a JS function. Props do sometimes have functions, but don't permit them everywhere.

Reviewed By: johnislarry

Differential Revision: D6541878

fbshipit-source-id: b2a9d3ba7899dfb98a6a2ada3aa91a26549fdd94

arthuralee/react-native,ptmt/react-native-macos,pandiaraj44/react-native,javache/react-native,ptmt/react-native-macos,dikaiosune/react-native,hammerandchisel/react-native,javache/react-native,dikaiosune/react-native,facebook/react-native,janicduplessis/react-native,exponentjs/react-native,exponent/react-native,javache/react-native,exponentjs/react-native,hoastoolshop/react-native,ptmt/react-native-macos,hammerandchisel/react-native,dikaiosune/react-native,javache/react-native,arthuralee/react-native,hoastoolshop/react-native,exponentjs/react-native,exponentjs/react-native,janicduplessis/react-native,rickbeerendonk/react-native,pandiaraj44/react-native,rickbeerendonk/react-native,exponentjs/react-native,facebook/react-native,jevakallio/react-native,facebook/react-native,hoangpham95/react-native,myntra/react-native,hoastoolshop/react-native,dikaiosune/react-native,myntra/react-native,exponent/react-native,rickbeerendonk/react-native,janicduplessis/react-native,pandiaraj44/react-native,exponent/react-native,rickbeerendonk/react-native,ptmt/react-native-macos,myntra/react-native,myntra/react-native,exponent/react-native,javache/react-native,hoangpham95/react-native,arthuralee/react-native,exponentjs/react-native,pandiaraj44/react-native,jevakallio/react-native,jevakallio/react-native,arthuralee/react-native,janicduplessis/react-native,dikaiosune/react-native,hoangpham95/react-native,facebook/react-native,myntra/react-native,dikaiosune/react-native,hoastoolshop/react-native,hammerandchisel/react-native,myntra/react-native,hoangpham95/react-native,myntra/react-native,jevakallio/react-native,jevakallio/react-native,exponentjs/react-native,javache/react-native,facebook/react-native,exponent/react-native,facebook/react-native,janicduplessis/react-native,pandiaraj44/react-native,rickbeerendonk/react-native,hammerandchisel/react-native,hoastoolshop/react-native,exponent/react-native,rickbeerendonk/react-native,javache/react-native,arthuralee/react-native,janicduplessis/react-native,dikaiosune/react-native,dikaiosune/react-native,pandiaraj44/react-native,myntra/react-native,hoangpham95/react-native,jevakallio/react-native,hammerandchisel/react-native,hoastoolshop/react-native,ptmt/react-native-macos,exponent/react-native,ptmt/react-native-macos,hoangpham95/react-native,facebook/react-native,javache/react-native,jevakallio/react-native,exponent/react-native,facebook/react-native,hoastoolshop/react-native,hoastoolshop/react-native,myntra/react-native,ptmt/react-native-macos,javache/react-native,jevakallio/react-native,rickbeerendonk/react-native,janicduplessis/react-native,pandiaraj44/react-native,janicduplessis/react-native,hoangpham95/react-native,hoangpham95/react-native,hammerandchisel/react-native,pandiaraj44/react-native,hammerandchisel/react-native,ptmt/react-native-macos,facebook/react-native,jevakallio/react-native,hammerandchisel/react-native,exponentjs/react-native,rickbeerendonk/react-native,rickbeerendonk/react-native