Skip to content

Instantly share code, notes, and snippets.

@d-dmytro
d-dmytro / apollo.tsx
Last active February 15, 2022 11:13
Types for the Apollo setup file from the Next's "with-apollo" example (https://github.com/zeit/next.js/tree/canary/examples/with-apollo). If you've got a suggestion how to improve this, please post it in the comments section.
import React from 'react';
import Head from 'next/head';
import { ApolloProvider } from '@apollo/react-hooks';
import { ApolloClient } from 'apollo-client';
import { InMemoryCache } from 'apollo-cache-inmemory';
import { HttpLink } from 'apollo-link-http';
import fetch from 'isomorphic-unfetch';
import { NextPage } from 'next';
export type AppApolloCache = any;
set encoding=utf-8
set history=500
filetype plugin on
filetype indent on
" Set leader key
let mapleader = "\<Space>"
" Remove search highlight