react-native-web is a library aims to make react-native projects able to run in web browser, by providing the same Components and APIs of react-native for web.
Questions tagged [react-native-web]
534 questions
                    
                    27
                    
            votes
                
                2 answers
            
        how to use react-native-web and react-navigation together and access from web url
UPDATE:
react-navigation web support is done. follow this:
https://reactnavigation.org/docs/en/web-support.html
ORIGIN:
I try to share my code between react-native and web.
when I try react-native-web, it works well.
but there is only one question,…
         
    
    
        GeminiYellow
        
- 1,016
- 2
- 12
- 34
                    17
                    
            votes
                
                4 answers
            
        react-native-web, DatePicker component?
I was hoping to use https://github.com/xgfe/react-native-datepicker with react-native-web but it's not compatible I think.
Is there other library that offers native datepicker look as in the image which are compatible with react-native-web?
         
    
    
        eugene
        
- 39,839
- 68
- 255
- 489
                    17
                    
            votes
                
                3 answers
            
        how to solve this error You may need an appropriate loader to handle this file type
I got this error with this library https://github.com/react-native-web-community/react-native-web-linear-gradient/
the error link
https://github.com/react-native-web-community/react-native-web-linear-gradient/issues/1
details of error:
Module parse…
         
    
    
        amorenew
        
- 10,760
- 10
- 47
- 69
                    16
                    
            votes
                
                0 answers
            
        Is there any react-native-web compatible date picker?
I'm currently working on a react-native project using expo.
A lot of the react-native components I'm using translate well with react-native-web.
I'm having a hard time finding a date-picker library that renders properly on both IOS/Android and…
         
    
    
        Gaber
        
- 161
- 5
                    16
                    
            votes
                
                3 answers
            
        React-Native-Web vs ReactJS
Just happened to see React-Native-Web(RNW) , my thought was
what? Why do we need another React for Web version? We have already had ReactJS(RJS).
So I went to its website and saw the document saying it allows you to use Native component by using…
         
    
    
        Franva
        
- 6,565
- 23
- 79
- 144
                    15
                    
            votes
                
                3 answers
            
        Warning: Failed prop type: Invalid prop `value` of type `number` supplied to `TextInput`, expected `string`
in react-native, I have: 
Warning: Failed prop type: Invalid prop `value` of type `number` supplied to `TextInput`, expected `string`.
I have a postalCode and it is numeric value.
I have set the keyboardType="numeric" on 
         
    
    
        Dimitri Kopriwa
        
- 13,139
- 27
- 98
- 204
                    14
                    
            votes
                
                2 answers
            
        Expo Web failed to compile "optional chaining"
Looks like Expo Webpack doesn't optional chaining.
I found this when I tried to install UI Kitten to Expo Web app. 
This is the compile error after I added UI Kitten to the newly created Expo…
         
    
    
        sujameslin
        
- 181
- 1
- 7
                    13
                    
            votes
                
                3 answers
            
        Change border color of TextInput when focused in react-native-web (expo)
In the last versions of Expo there is a Web support. In the picture you see a normal TextInput created with React Native & rendered in the Web.
How can I change the color of the TextInput Border that is activated on focus? You see an orange border…
         
    
    
        Arbnor
        
- 2,190
- 18
- 26
                    12
                    
            votes
                
                2 answers
            
        How to use PostMessage in a React Native webview?
I'm trying to use the postmessage to a page opened in a webview inside a React Native App. I tried many times, but still wasn't able to send it.
I can listen to messages from the webpage normally. I just can't send anything back.
I'm currently using…
         
    
    
        Felipe César
        
- 1,234
- 2
- 16
- 34
                    11
                    
            votes
                
                1 answer
            
        react-navigation for react-native-web?
Need to reuse the react-navigation code from mobile to react-native-web. But I could not able to get it work in web.
Should we need to use react-router for web separately? 
How can we configure navigation commonly for both platform? 
I would love…
         
    
    
        Balasubramanian
        
- 5,274
- 6
- 33
- 62
                    11
                    
            votes
                
                4 answers
            
        styled components :hover with react-native and react-native-web
I'm using styled-components in React-Native App.
Let's say I have link component:
import styled from 'styled-components/native';
const Link = styled.Text`
  color: 'red';
  &:hover {
    color: 'blue';
  }
`
After that, I 'compile' my…
         
    
    
        Dávid Ďurika
        
- 111
- 1
- 1
- 5
                    10
                    
            votes
                
                2 answers
            
        How to override React native web pre defined css
I'm Converting my expo app to react-native-web, I have an issue when I'm showing Image. by default react-native-web adding a class to Image with position:absolute. I want to override that class, here is my code.
React-native Code
    
        
            
            
                
                    
    
    
         
    
    
                
            
        
      
 
    
    
        zulqarnain
        
- 1,536
- 4
- 26
- 44
                    10
                    
            votes
                
                2 answers
            
        How do I access children components of a reference in React Native Web?
I have some references in a React Native Web application - these references work on React Native, but not RNW.
For example, I have this code:
this.highlight.current._children[i].setNativeProps({ style: { backgroundColor: "black" }…
         
    
    
        Steven Matthews
        
- 9,705
- 45
- 126
- 232
                    10
                    
            votes
                
                8 answers
            
        how to make react native web full height?
I am using react native web library but I can't make full height on web
Code:
import React from 'react';
import {StyleSheet, View, Text, TouchableOpacity} from 'react-native';
class index extends React.Component {
    render() {
        return (
 …
         
    
    
        amorenew
        
- 10,760
- 10
- 47
- 69
                    9
                    
            votes
                
                2 answers
            
        How do I populate the initialState in Redux from react native's AsyncStorage?
I have a React Native app. I am storing username and uid in AsyncStorage so they don't have to log in every time. How do I populate the initialState with these values. There are some packages that do it for you but it seems like this should be…
         
    
    
        Steve Carey
        
- 2,876
- 23
- 34