I had pushed this schema.graphql
:
type Post @model {
id: ID!
title: String!
slug: String!
content: String!
createdAt: String!
// MyApp/src/app/Root.js | |
// @flow | |
import * as React from 'react' | |
import { ApolloProvider } from 'react-apollo' | |
import App from './App'; | |
type Props = { | |
graphqlClient: any |
// 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'; |
// 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' |
// 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" |
ββ MyApp | |
βββ src | |
βββ app | |
β βββ index.js | |
β βββ Root.js | |
β βββ App.js | |
β βββ config | |
β β βββ index.js | |
β βββ components | |
β β βββ index.js |
// 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 |
NODE_PATH=. |
I had pushed this schema.graphql
:
type Post @model {
id: ID!
title: String!
slug: String!
content: String!
createdAt: String!