Setting up the environment
What's good about Node.js and Puppeteer is that they are cross-platform. My local environment is macOS Catalina 10.15.6. But you won't see much difference if you use a Windows or a Linux environment.
Time is a tech book's worst enemy. At the time of writing this book, I was using Node.JS 12.18.3 and Puppeteer 7. I'm pretty sure that by the time you read this book, new versions will have come to light. But don't feel discouraged about that; we expect that to happen. That's why I encourage you to go now and take a look at the GitHub repository of this book (https://github.com/PacktPublishing/ui-testing-with-Puppeteer). If you see that something is not working or has changed, please create an issue on that repository. We will try to keep it updated.
We only need two things to run our first Puppeteer code: Node.JS and Puppeteer. Let's begin with Node.JS.
Node.js
For the purposes of this book, the only thing you need...