Progress
This commit is contained in:
@@ -11,19 +11,19 @@ const FEED_SEARCH_QUERY = gql`
|
||||
id
|
||||
links {
|
||||
id
|
||||
url
|
||||
title
|
||||
description
|
||||
createdAt
|
||||
type
|
||||
createdBy {
|
||||
id
|
||||
name
|
||||
}
|
||||
follows {
|
||||
id
|
||||
user {
|
||||
id
|
||||
}
|
||||
username
|
||||
}
|
||||
# follows {
|
||||
# id
|
||||
# user {
|
||||
# id
|
||||
# }
|
||||
# }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -30,7 +30,6 @@ const authLink = setContext((_, { headers }) => {
|
||||
|
||||
const client = new ApolloClient({
|
||||
link: authLink.concat(httpLink),
|
||||
// link: httpLink,
|
||||
cache: new InMemoryCache()
|
||||
});
|
||||
|
||||
@@ -45,34 +44,14 @@ ReactDOM.render(
|
||||
// serviceWorker.unregister();
|
||||
|
||||
|
||||
// import { setContext } from '@apollo/client/link/context';
|
||||
// import { AUTH_TOKEN } from './constants';
|
||||
|
||||
// import { split } from '@apollo/client';
|
||||
// import { WebSocketLink } from '@apollo/client/link/ws';
|
||||
// import { getMainDefinition } from '@apollo/client/utilities';
|
||||
// // import AppointmentList from './components/AppointmentList';
|
||||
|
||||
// // class App extends Component {
|
||||
// // render() {
|
||||
// // return <AppointmentList />;
|
||||
// // }
|
||||
// // }
|
||||
|
||||
// // export default App;
|
||||
|
||||
|
||||
// // attach the auth_token to all requests to GraphQL server
|
||||
// const authLink = setContext((_, { headers }) => {
|
||||
// const token = localStorage.getItem(AUTH_TOKEN);
|
||||
// return {
|
||||
// headers: {
|
||||
// ...headers,
|
||||
// authorization: token ? `Bearer ${token}` : ''
|
||||
// }
|
||||
// };
|
||||
// });
|
||||
|
||||
// const wsLink = new WebSocketLink({
|
||||
// uri: `ws://localhost:4000/graphql`,
|
||||
// options: {
|
||||
@@ -95,13 +74,4 @@ ReactDOM.render(
|
||||
// authLink.concat(httpLink)
|
||||
// );
|
||||
|
||||
// // 3
|
||||
// const client = new ApolloClient({
|
||||
// link,
|
||||
// cache: new InMemoryCache()
|
||||
// });
|
||||
|
||||
// // If you want to start measuring performance in your app, pass a function
|
||||
// // to log results (for example: reportWebVitals(console.log))
|
||||
// // or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
|
||||
// // reportWebVitals();
|
||||
|
||||
Reference in New Issue
Block a user