{"size": 245, "ext": "js", "max_stars_repo_path": "puppeteer-service/src/compress.js", "max_stars_repo_name": "kpatel20538/bookmarks-app", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "puppeteer-service/src/compress.js", "max_issues_repo_name": "kpatel20538/bookmarks-app", "max_issues_repo_issues_event_min_datetime": "2022-01-22T13:03:43.000Z", "max_issues_repo_issues_event_max_datetime": "2022-02-13T17:47:26.000Z", "max_forks_repo_path": "puppeteer-service/src/compress.js", "max_forks_repo_name": "kpatel20538/bookmarks-app", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 2, "max_forks_count": null, "avg_line_length": 24.5, "max_line_length": 49, "alphanum_fraction": 0.6816326531}
const imagemin = require("imagemin");
const pngquant = require("imagemin-pngquant");

const compress = async (uncompressed) =>
  imagemin.buffer(uncompressed, {
    plugins: [pngquant({ quality: [0.6, 0.8] })],
  });

module.exports = compress;
