aboutsummaryrefslogtreecommitdiffstats
path: root/pages/_app.js
blob: 46252911aa5895dfb504485c20ec8ec7a6aa89cf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import { SWRConfig } from 'swr'
import fetchJson from 'lib/fetchJson'
import '/styles/global.scss'

function MyApp({Component, pageProps}) {
  return (
    <SWRConfig
      value={{
        fetcher: fetchJson,
        onError: (err) => {
          console.error(err)
        },
      }}
    >
      <Component {...pageProps} />
    </SWRConfig>
  )
}

export default MyApp