Skip to content

Instantly share code, notes, and snippets.

View tabvn's full-sized avatar

Toan tabvn

  • Danang, Vietnam
View GitHub Profile
import React, {Component} from 'react'
import {apolloClient} from './client'
import {ApolloProvider} from '@apollo/react-hooks'
class App extends Component {
render() {
return (
<ApolloProvider client={apolloClient}>
import { split } from 'apollo-link';
import { HttpLink } from 'apollo-link-http';
import { WebSocketLink } from 'apollo-link-ws';
import { getMainDefinition } from 'apollo-utilities';
import {setContext} from 'apollo-link-context'
import {InMemoryCache} from 'apollo-cache-inmemory'
import {ApolloClient} from 'apollo-client'
const authLink = setContext((_, {headers}) => {
#include <iostream>
#include <vector>
using namespace std;
struct Result
{
int fromIndex, len;
long long total;
#include "Windows.h"
#include <iostream>
#include <conio.h>
#include <cmath>
#include <vector>
#include <string>
#include <sstream>
using namespace std;
query tineline {
timeline(filter: "everyone", limit: 10, offset: 0) {
id
timeline {
id
entityType
entityId
entity {
__typename
... on User {
query timeLine {
timeline(filter: "everyone") {
id
timeline {
entityId
entityType
entity{
...on User{
id
avatar
query post{
post(id: 53){
id
body
postType
created
updated
pinned
commentCount
mutation createMessage{
createMessage(roomId:18, body:"Hi there how are you?", messageType: "default"){
id
body
messageType
author{
id
username
avatar
isOnline
query findFriends{
findFriends(search: "", limit:null, offset: null){
id
firstName
username
avatar
email
}
}
query forumTopic{
forumTopic(id:1){
id
body
author{
id
username
firstName
lastName
}