code: function cleanDistDir(dir) {
    /* istanbul ignore else */
    if (dir !== process.cwd()) {
      fs.stat(dir, (err) => {
        if (!err) {
          del.sync([dir]);
        }
  
        fs.mkdirSync(dir);
      });
    }
  }
docs: Remove old dist directory and make a new dist directory.
  @param {string} dir The dist directory.