Skip to content

Commit

Permalink
Update going-to-production.md
Browse files Browse the repository at this point in the history
  • Loading branch information
balazsorban44 committed Mar 16, 2022
1 parent 70ac82e commit 3f76c1a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions docs/going-to-production.md
Expand Up @@ -68,6 +68,7 @@ export async function getServerSideProps({ req, res }) {
}
}
```

By default, `Cache-Control` headers will be set differently depending on how your page fetches data.

If the page is using `getServerSideProps` or `getInitialProps`, then it will use the default `Cache-Control` header configured by `next start` in order to prevent accidental caching of responses that cannot be cached. If you want a different cache behavior while using SSR you can use `res.setHeader('Cache-Control', 'value_you_prefer')`.
Expand Down

0 comments on commit 3f76c1a

Please sign in to comment.