Windows App plugin not working for react native - react-native

I'm trying to provide windows support for my react native app but somehow it's not able to generate windows folder.
the first error is...
rnpm-plugin-windows#0.2.11 requires a peer of react-native#>=0.31.0 but none is installed. You must install peer dependencies yourself.
Above error is coming when I entered the command npm install --save-dev rnpm-plugin-windows
Some time windows plugin is installed properly but below error will coming
"Windows" command not found when I entered react-native windows

You First React-native-cli install
npm install -g react-native-cli
npm install --save-dev rnpm-plugin-windows
react-native init yourproject
Usage
react-native windows [name] [--namespace <namespace>] [--windowsVersion <version>]

Related

React native unexpected error has ocurred

first time using react native. When i run npm start and open the localhost, it says "An unexpected error has ocurred". If i scan the QR code in the Expo app, it says "Something went wrong. Network responde timed out".
When i open the console this appears
I created the app as:
npm install -g expo-cli
expo init MyApp
Selected the typescript template
And then at the MyApp folder npm start
Its probably because of new version of expo-cli#5.4.10
Uninstall new version and install 5.4.7
For npm:
npm -g uninstall expo-cli
npm -g install expo-cli#5.4.7
For yarn:
yarn global remove expo-cli
yarn global add expo-cli#5.4.7

problem with expo react native navigation

i am using react-native with expo to run my app on my android devices when i load my app on my terminal i have this error
Some dependencies are incompatible with the installed expo package version:
#react-native-community/masked-view - expected version: 0.1.10 - actual version installed: 0.1.11
Your project may not work correctly until you install the correct versions of the packages.
To install the correct versions of these packages, please run: expo install [package-name ...]
Missing package "metro-config" in the project at: C:\Users\kabore\Desktop\react_native\app1
This usually means react-native is not installed. Please verify that dependencies in package.json include "react-native" and run yarn or npm install.
Error: Missing package "metro-config" in the project at: C:\Users\kabore\Desktop\react_nativ
simply remove the node_modules folder and run yarn install or npm install in the command line to install dependencies again .it seems like some of your dependencies are not installed correctly

expo install vs npm install

I'm just getting started with Expo -- but I've done RN development using the CLI. One of the first things I noticed is that I am supposed to install third party packages using expo install <package-name> so that we know the package is compatible.
However, I just noticed that even though Expo recommends React Navigation for navigation and routing, the first step in installing it is npm install #react-navigation/native. We then continue with expo install for installing Expo dependencies. Here's the instructions: https://reactnavigation.org/docs/getting-started/
I'm a bit confused here. I thought we weren't supposed to use npm install with Expo. What am I missing? Why are we using npm install for the React Navigation package and not expo install?

React native doesn't start metro bundler on chrome after i try to run npm start on terminal

metro bundler
I'm trying to run an app published by other programmer but it doesn't run metro bundler on google chrome when I type npm start on terminal.
On the other hand, I created a project and run it and it works
my project
Open new terminal and run below command, It will bring up expo dev client.
expo start --dev-client
Sometimes it might throw an error as below.
Missing package "metro/src/lib/attachWebsocketServer" in the project. This usually means react-native is not installed. Please verify that dependencies in package.json include "react-native" and run yarn or npm install.
To fixing this issue, run the command
npm install -g expo-cli
npm install expo-dev-client
expo start --dev-client
You need to install the dependencies of the other developer's project by running 'npm install' before starting metro bundler.

Expo Web starts Automatically

When I run the command "yarn start", the expo web starts automatically, and even if I open the expo client app on my iPhone the link on my app takes me to Safari and opens up a webpage. How can I open the app on expo CLI and not on my phone's browser (Safari)?
I have also tried the command "expo start --ios" and when I run it I get the error
"Simulator not installed. Please visit
https://developer.apple.com/xcode/download/ to download Xcode and the
iOS simulator. If you already have the latest version of Xcode
installed, you may have to run the command sudo xcode-select -s /Applications/Xcode.app".
I don't want to run the app on a simulator or phone's browser instead on my phone using expo client
I was dealing with this issue also hoping someone would find a solution. However, I have found the solution that worked for me at least. What I did is installed the react-native cli (reinstall if already installed) and then ran npm install in my project and it went back to normal and stopped going on my phones browser. Search documentation regarding this to install those things. I installed them in the order stated and it worked.
try update your expo-cli version and see if it helps. npm install -g expo-cli
Below is my situation,
By default Expo uses yarn. I installed any new dependencies using npm, then by default expo is built with web.
Solution:
use yarn always to install new dependencies or
use npm install once to install and now expo will build project with android or ios
On Linux try with sudo:
sudo npm install -g expo-cli
Then install packages and run:
yarn
Then run the following to clear cache and start expo:
expo start -c
This issue usually happens when you install a new npm package. You can either uninstall/reinstall the package or run the above three steps and solve your problem.