Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playground for windows #5644

Merged
merged 3 commits into from Nov 13, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions docs/docs/showcases.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,15 @@ The playground example is a place where we showcase and test all features of rea
git clone https://github.com/wix/react-native-navigation
cd react-native-navigation
npm install

# for iOS:
npm run xcode # Opens XCode
npm start # Starts the packager
npm start # Starts the packager on linux like systems

# for Android:
# 1. open Android Studio inside ".\playground"
# 2. start a emulator
npm run start-windows # Start the packager if you are on a windows system

# Run the app in Simulator or on Device from within XCode
# Run the app in Simulator or on Device from within XCode/Android Studio
```
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"clean": "node ./scripts/clean",
"prestart": "npm run build",
"start": "node ./scripts/start",
"start-windows": "node ./scripts/start-windows",
"pretest-js": "npm run build",
"test-js": "node ./scripts/test-js",
"test-unit-ios": "node ./scripts/test-unit --ios",
Expand Down
11 changes: 11 additions & 0 deletions scripts/start-windows.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
const exec = require('shell-utils').exec;

run();

function run() {
// exec.killPort(8081);
// exec.execSync(`rd "./lib/dist" /Q/S`);
exec.execSync(`"./node_modules/.bin/tsc"`);
exec.execSync(`adb reverse tcp:8081 tcp:8081`);
exec.execSync(`node ./node_modules/react-native/local-cli/cli.js start`);
}