hunk.code_window: import { cache as defaultCache } from './config'
   import { initCache } from './cache'
   import { mergeConfigs } from './merge-config'
   import { isFunction, UNDEFINED } from './helper'
   import {
     SWRConfiguration,
     FullConfiguration,
  
hunk.labels: keep keep keep replace keep keep keep
hunk.after_edit: import { UNDEFINED } from './helper'
   import { useIsomorphicLayoutEffect } from './env'
  
hunk.file_path: src/utils/config-context.ts
hunk.type: replace
file: import Link from 'next/link'
  
  import useSWR from 'swr'
  
  export default function Repo() {
    const id = typeof window !== 'undefined' ? window.location.pathname.slice(1) : ''
    const { data } = useSWR('/api/data?id=' + id)
  
    return <div style={{ textAlign: 'center' }}>
      <h1>{id}</h1>
      {
        data ? <div>
          <p>forks: {data.forks_count}</p>
          <p>stars: {data.stargazers_count}</p>
          <p>watchers: {data.watchers}</p>
        </div> : 'loading...'
      }
      <br />
      <br />
      <Link href="/"><a>Back</a></Link>
    </div>
  }
  