getInitialProps
(deprecated) SSR에서는 서버와 클라이언트 사이에 context를 유지하기 위해 데이터를 클라이언트에게 넘겨줄 필요가 있다
__NEXT_DATA__ 로 전달Next.js Data Fetching
document
Basic Features: Data Fetching | Next.js
This document is for Next.js versions 9.3 and up. If you're using older versions of Next.js, refer to our previous documentation. In the Pages documentation, we've explained that Next.js has two forms of pre-rendering: Static Generation and Server-side Rendering. In this page, we'll talk in depth about data fetching strategies for each case.
https://nextjs.org/docs/basic-features/data-fetching

korean
[Next.js] getStaticProps와 getServerSideProps
Next.js 9.3 미만 버전에서 SSR(Server Side Rendering), SSG(Static Site Generation)를 적용하기 위해서는 getInitialProps 메소드가 활용되었습니다. getInitialProps 를 통해 서버에서 미리 필요한 데이터들을 패칭 후 html 파일에 렌더링하고 클라이언트에 전송하여 SEO를 향상할 수 있었습니다. Next.js 9.3 이상 버전부터 SSR, SSG를 지원하기 위한 새로운 메소드가 등장하였습니다. getStaticProps, getServerSideProps 입니다.
https://nunucompany.tistory.com/5
Component Level
Component-level data fetching in Next.js (with SSR)
Next.js is a fantastic framework for building react apps but - due to the way react works - there is one feature that it currently does not support: component-level data fetching on the server. At the time of writing this, the mechanisms Next ofers for data fetching on the server are at the page-level or above.
https://medium.com/@A__G__B/component-level-data-fetching-in-next-js-with-srr-8d35cdc5849e

Next - 기본편 - Tlog
Next.js 기본 다루기 (NextJS, React, SSR)
https://tlog.tammolo.com/posts/nextjs-basic

Seonglae Cho