The codelab has the full instructions, but as a quick start, you can do this.
firebase emulators:start --project demo-codelab-nextjs
Copy the file lib/firebase/config-copy.js
to lib/firebase/config.js
and fill in the values from the Firebase console.
In a new terminal tab/window, run:
npm i
npm run dev
http://localhost:3000
http://localhost:3000/
within your browser, click the "Sign in" button in the top right corner and sign in.