This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
render() { | |
return ( | |
<View style={styles.container} accessibilityLabel="testview"> | |
<Text style={styles.welcome}> | |
Welcome to React Native! | |
</Text> | |
... | |
) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import wd from 'wd'; | |
jasmine.DEFAULT_TIMEOUT_INTERVAL = 60000; | |
const PORT = 4723; | |
const config = { | |
platformName: 'Android', | |
deviceName: 'Android Emulator', | |
app: './android/app/build/outputs/apk/app-debug.apk' // relative to root of project | |
}; | |
const driver = wd.promiseChainRemote('localhost', PORT); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "appiumTutorial", | |
"version": "0.0.1", | |
"private": true, | |
"scripts": { | |
"start": "node node_modules/react-native/local-cli/cli.js start", | |
"test": "source venv/bin/activate && LOCATION='local' py.test && deactivate", | |
"appium": "appium", | |
"appium:doctor": "appium-doctor" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default ({ body, title }) => (` | |
<!DOCTYLE html> | |
<html> | |
<head> | |
<title>${title}</title> | |
</head> | |
<body> | |
<div id="root">${body}</div> | |
</body> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import express from 'express'; | |
import webpack from 'webpack'; | |
import webpackConfig from '../webpack/webpack.config.dev-client'; | |
const render = require('../dist/assets/SSR'); | |
const app = express(); | |
const compiler = webpack(webpackConfig); | |
app.use(require('webpack-dev-middleware')(compiler, { | |
noInfo: true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { publicPath, assetsPath, commonLoaders } = require('./common.config'); | |
const path = require('path'); | |
const nodeExternals = require('webpack-node-externals'); | |
module.exports = { | |
name: 'SSR', | |
context: path.join(__dirname, '..', 'app'), | |
entry: './SSR.js', | |
output: { | |
path: assetsPath, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { publicPath, assetsPath, commonLoaders } = require('./common.config'); | |
const webpack = require('webpack'); | |
const path = require('path'); | |
module.exports = { | |
devtool: 'eval', | |
name: 'client', | |
context: path.join(__dirname, '..', 'app'), | |
entry: './client.js', | |
output: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
module.exports = { | |
publicPath: '/assets/', | |
assetsPath: path.join(__dirname, '..', 'dist', 'assets'), | |
commonLoaders: [ | |
{ | |
test: /\.js$/, | |
loader: 'babel', | |
include: path.join(__dirname, '..', 'app'), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import styles from './App.css' | |
export default class App extends Component { | |
render() { | |
return ( | |
<div className={styles.wrapper}> | |
Hello world! | |
</div> | |
); |