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
0
votes
1 answer
React Native Web, data-attributes doesn't work?
https://reactjs.org/docs/faq-functions.html#example-passing-params-using-data-attributes .
Essentially, it is an optimization of arrow function
this.handleClick(letter)}>
{letter}
to the…

eugene
- 39,839
- 68
- 255
- 489
0
votes
0 answers
TypeError: Cannot read property 'navigate' of undefined React Native Web
Friends I am just started with react native for web.
I am having the issues at navigation. When I am navigating from Emulator Android I am not having any problem with navigation. It navigate to Page2 at android. But When I open My localhost:3000 Web…

Harjinder Singh
- 1
- 1
0
votes
0 answers
Hide a part of WebView in react native
I would like to know if it is possible to hide some part of a webView. For example, I'm using youtube and I would like to hide the search bar on top of the webView. Is this possible ?
I tried with putting a view with a height but it's not…

Jats1596
- 1,117
- 1
- 13
- 20
0
votes
1 answer
Strange React Native Web Error After Update
We are using react-native-web to build a project and after updating all of our dependencies this morning we’re getting the following error in the console for most of the components in the project:
Cannot read property ‘forEach' of undefined…

Nick Parsons
- 8,377
- 13
- 48
- 70
0
votes
1 answer
React-navigation + react-native-web for web project, how to navigate to correct screen using url
I'm trying to use react-navigation and react-native-web as described in https://reactnavigation.org/docs/en/web-support.html (nothing much.. just says it's possible)
If a user sends a link to his friend example.com/some/path I'd like to show him…

eugene
- 39,839
- 68
- 255
- 489
0
votes
1 answer
Can't resolve 'react-native' in 'react-native-vector-icon'
I am using react-native-web and webpack in my project, I need to show icons in my web app, I am trying to use react-native-web-vector-icons.
But I am getting the following error:
./node_modules/react-native-vector-icons/lib/react-native.js Module
…

Isha Narola
- 1
- 2
0
votes
0 answers
React native not encoding images correctly in web
Hi I want to show a local image in my react native web app. But it does not work correctly.
src of img tag:…

sina sadeghi
- 21
- 1
- 3
0
votes
1 answer
Django-cors-headers does not work with Expo-web
I just ran an Expo-web development server at http://192.168.0.6:19006 and there appears many problems.
When I did not install django-cors-headers, only the main page was loaded and any others requests all failed. I soon realized that I had to…

Grateful
- 383
- 5
- 18
0
votes
1 answer
AsyncStorage is null when using with react native web
I am trying to use async storage with "react native web" but it is saying " AsyncStorage is null".
commands I ran:
yarn add @react-native-community/async-storage
react-native link @react-native-community/async-storage
When I try to open…

user2349115
- 1,288
- 2
- 17
- 34
0
votes
1 answer
Securing private keys with ReactNativeWeb
I'm working on an app on react native web, and want to secure my calls.
I thought about crypting body to prevent sniffing but that would mean setting my private key (to decipher response body) in the code (could be decompiled -> not secure).
I will…

Phoque
- 217
- 3
- 14
0
votes
1 answer
Code splitting with webpack with single entry point
I am new to webpack and trying to figure out how to have the code splitting working.
I have a large bundle created from react-native-web and I want to split it into two smaller ones. One will include all node_modules and the other one my custom…

PoppyAnc
- 131
- 1
- 2
- 9
0
votes
0 answers
TouchableHighlight affects padding
I have react-native-web project.
A problem I'm having is that when a TouchableHighlight is pressed, the padding of all the children elements is removed.
Before the touch, the inspector shows proper padding, after the touch padding is 0. I've tried…

Anton
- 2,282
- 26
- 43
0
votes
0 answers
How to conditionally import react-native-vector-icons dist for web
When using react-native-vector-icons on web, you have to use react-native-vector-icons/dist, per the README.
However, on a native app this results in an error that "react-native-vector-icons/dist" is not in the hashmap and couldn't be resolved.
What…

Varun Singh
- 1,676
- 3
- 18
- 25
0
votes
1 answer
Webpack Parse Error: Unexpected token (8:2) You may need an appropriate loader to handle this file type
I am trying to intigrate react-native-web with an existing react-native app, I have followed https://github.com/necolas/react-native-web/blob/master/docs/guides/multi-platform-apps.md instructions,
Unable to parse the any JSX code, due to Module…

srikanth
- 308
- 3
- 13
0
votes
1 answer
How could react-native-web use react-native import?
How could we import react-native when it's not installed on dependency when using react-native-web? The sample here: https://codesandbox.io/s/q4qymyp2l6

Inovramadani
- 1,955
- 3
- 14
- 34