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
.App { | |
display: flex; | |
width: 100vw; | |
height: 100vh; | |
overflow: hidden; | |
} |
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
import React from 'react'; | |
import LaunchList from './components/LaunchList'; | |
import LaunchProfile from './components/LaunchProfile'; | |
import './App.css'; | |
const App = () => { | |
return ( | |
<div className="App"> | |
<LaunchList /> |
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
.LaunchProfile { | |
height: 100vh; | |
max-height: 100%; | |
width: calc(100vw - 300px); | |
overflow: hidden auto; | |
padding-left: 20px; | |
padding-right: 20px; | |
} | |
.LaunchProfile__status { |
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
import * as React from 'react'; | |
import { LaunchProfileQuery } from '../../generated/graphql'; | |
import './styles.css'; | |
interface Props { | |
data: LaunchProfileQuery; | |
} | |
const className = 'LaunchProfile'; |
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
import * as React from 'react'; | |
import { useLaunchProfileQuery } from '../../generated/graphql'; | |
import LaunchProfile from './LaunchProfile'; | |
const LaunchProfileContainer = () => { | |
const { data, error, loading } = useLaunchProfileQuery({ variables: { id: '42' } }); | |
if (loading) { | |
return <div>Loading...</div>; | |
} |
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
.LaunchList { | |
height: 100vh; | |
overflow: hidden auto; | |
background-color: #ececec; | |
width: 300px; | |
padding-left: 20px; | |
padding-right: 20px; | |
} | |
.LaunchList__list { |
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
import * as React from 'react'; | |
import { LaunchListQuery } from '../../generated/graphql'; | |
import './styles.css'; | |
interface Props { | |
data: LaunchListQuery; | |
} | |
const className = 'LaunchList'; |
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
import * as React from 'react'; | |
import { useLaunchListQuery } from '../../generated/graphql'; | |
import LaunchList from './LaunchList'; | |
const LaunchListContainer = () => { | |
const { data, error, loading } = useLaunchListQuery(); | |
if (loading) { | |
return <div>Loading...</div>; | |
} |
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
import * as React from 'react'; | |
import { useLaunchListQuery } from '../../generated/graphql'; | |
import LaunchList from './LaunchList'; | |
const LaunchListContainer = () => { | |
const { data, error, loading } = useLaunchListQuery(); | |
if (loading) { | |
return <div>Loading...</div>; | |
} |
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
import React from 'react'; | |
import ReactDOM from 'react-dom'; | |
import ApolloClient from 'apollo-boost'; | |
import { ApolloProvider } from 'react-apollo'; | |
import { ApolloProvider as ApolloHooksProvider } from 'react-apollo-hooks'; | |
import './index.css'; | |
import App from './App'; | |
const client = new ApolloClient({ | |
uri: 'https://spacexdata.herokuapp.com/graphql', |