Skip to content

Not working in react-native-web #91

@learncodingforweb

Description

@learncodingforweb

WARNING in ./node_modules/react-native-button/Button.js 154:18-37
export 'ViewPropTypes' (imported as 'ViewPropTypes') was not found in 'react-native-web/dist/index' (possible exports: AccessibilityInfo, ActivityIndicator, Alert, Animated, AppRegistry, AppState, Appearance, BackHandler, Button, CheckBox, Clipboard, DeviceEventEmitter, DeviceInfo, Dimensions, DrawerLayoutAndroid, Easing, FlatList, I18nManager, Image, ImageBackground, InputAccessoryView, InteractionManager, Keyboard, KeyboardAvoidingView, LayoutAnimation, Linking, LogBox, Modal, NativeEventEmitter, NativeModules, PanResponder, PermissionsAndroid, Picker, PixelRatio, Platform, Pressable, ProgressBar, RefreshControl, SafeAreaView, ScrollView, SectionList, Settings, Share, StatusBar, StyleSheet, Switch, Systrace, TVEventHandler, Text, TextInput, ToastAndroid, Touchable, TouchableHighlight, TouchableNativeFeedback, TouchableOpacity, TouchableWithoutFeedback, UIManager, Vibration, View, VirtualizedList, YellowBox, findNodeHandle, processColor, render, unmountComponentAtNode, unstable_createElement, useColorScheme, useWindowDimensions)

browser shows error

Uncaught TypeError: Cannot read property 'allowFontScaling' of undefined
    at eval (Button.js:168)
    at Module../node_modules/react-native-button/Button.js (bundle.js:41)
    at __webpack_require__ (bundle.js:3038)
    at eval (Home.js:9)
    at Module../src/Home.js (bundle.js:74)
    at __webpack_require__ (bundle.js:3038)
    at eval (App.js:9)
    at Module../src/App.js (bundle.js:63)
    at __webpack_require__ (bundle.js:3038)
    at eval (index.js:4)

using following packages

"dependencies": {
    "react": "^17.0.1",
    "react-dom": "^17.0.1",
    "react-native-button": "^3.0.1",
    "react-native-web": "^0.15.6"
  },

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions