`canvas` has been added to the dependency, not devDependency, since v3.0.279. I don't think it is a good idea. Because `node-canvas` prebuilds aren't available for ARM, users with macOS on ARM will request helps from you, which would increase the maintenance burden. We can say the same thing for users with old Linux for which `node-canvas` prebuilds aren't available.

When GitHub actions supports macOS on ARM, the situation would change.

- https://github.com/Automattic/node-canvas/issues/1511

- https://github.com/mozilla/pdfjs-dist/blob/f6eefc659269fe422cc350fe2eef769251eec33d/package.json#L15-L18
```json
  "dependencies": {
    "canvas": "^2.10.1",
    "web-streams-polyfill": "^3.2.1"
  },
```

Configuration:
- PDF.js version: 3.0.279

console.log();
  console.log("### Creating baseline environment");
  const baselineCommit = process.env.BASELINE;
  if (!baselineCommit) {
    done(new Error("Missing baseline commit. Specify the BASELINE variable."));
    return;
  }
  let initializeCommand = "git fetch origin";
  if (!checkDir(BASELINE_DIR)) {
    mkdirp.sync(BASELINE_DIR);
    initializeCommand = "git clone ../../ .";
  }
  const workingDirectory = path.resolve(process.cwd(), BASELINE_DIR);
  exec(initializeCommand, { cwd: workingDirectory }, function (error) {
    if (error) {
      done(new Error("Baseline clone/fetch failed."));
      return;
    }
    exec(
      "git checkout " + baselineCommit,
      { cwd: workingDirectory },
      function (error2) {
        if (error2) {
          done(new Error("Baseline commit checkout failed."));
          return;
        }
        console.log('Baseline commit "' + baselineCommit + '" checked out.');
        done();