This file contains hidden or 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
NODE_PATH=. |
This file contains hidden or 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
// by default it will look for `.mdx` files into the `./presentations` folder | |
const testFolder = './presentations'; | |
const fs = require('fs'); | |
const path = require('path'); | |
const prompts = require('prompts'); | |
const cmd = require('node-cmd'); | |
if (!fs.existsSync(testFolder)) { | |
// testFolder does not exist |
This file contains hidden or 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
── MyApp | |
└── src | |
├── app | |
│ ├── index.js | |
│ ├── Root.js | |
│ ├── App.js | |
│ ├── config | |
│ │ └── index.js | |
│ ├── components | |
│ │ ├── index.js |
This file contains hidden or 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
// MyApp/src/app/navigators/routes.js | |
// @flow | |
export const PRIVATE_ROUTE: string = 'PRIVATE_ROUTE' | |
export const PUBLIC_ROUTE: string = 'PUBLIC_ROUTE' | |
export const SIGNIN_ROUTE: string = "SIGNIN_ROUTE" | |
export const HOME_ROUTE: string = "HOME_ROUTE" | |
export const HOME_SCREEN_ROUTE: string = "HOME_SCREEN_ROUTE" |
This file contains hidden or 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
// MyApp/src/app/navigators/index.js | |
// @flow | |
import * as React from 'react' | |
import { SwitchNavigator } from 'react-navigation' | |
import PrivateRoot from './PrivateRootNavigator' | |
import PublicRoot from './PublicRootNavigator' | |
import { PRIVATE_ROUTE, PUBLIC_ROUTE } from './routes' |
This file contains hidden or 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
// MyApp/src/app/index.js | |
import React, { Component } from 'react'; | |
import { API_URL } from './config'; | |
import ApolloClient from 'apollo-client'; | |
import { HttpLink } from 'apollo-link-http'; | |
import { InMemoryCache } from 'apollo-cache-inmemory'; | |
import Root from './Root'; |
This file contains hidden or 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
// MyApp/src/app/Root.js | |
// @flow | |
import * as React from 'react' | |
import { ApolloProvider } from 'react-apollo' | |
import App from './App'; | |
type Props = { | |
graphqlClient: any |
This file contains hidden or 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
// MyApp/src/app/App.js | |
// @flow | |
import * as React from 'react' | |
import { Font } from 'expo' | |
import { isSignedIn } from '../auth/utils/auth' | |
import { createPrivateRootNavigator, createPublicRootNavigator } from './navigators' | |
type State = { | |
fontLoaded: boolean, |