hunk.code_window:   pages: any
     pageCount: number
     pageSWRs: responseInterface<any, any>[]
     isLoadingMore: boolean
     isReachingEnd: boolean
     isEmpty: boolean
  
hunk.labels: keep keep replace keep keep keep
hunk.after_edit:   pageSWRs: responseInterface<Data, Error>[]
  
hunk.file_path: src/types.ts
hunk.type: replace
file: import fetch from 'isomorphic-unfetch'
  
  const projects = [
    'facebook/flipper', 'vuejs/vuepress', 'rust-lang/rust', 'zeit/next.js'
  ]
  
  export default (req, res) => {
    if (req.query.id) {
      // a slow endpoint for getting repo data
      fetch(`https://api.github.com/repos/${req.query.id}`)
        .then(resp => resp.json())
        .then(data => {
          setTimeout(() => {
            res.json(data)
          }, 2000)
        })
      
      return
    }
    setTimeout(() => {
      res.json(projects)
    }, 2000)
  }
  