Skip to content

Commit

Permalink
prefer faster oxipng compression
Browse files Browse the repository at this point in the history
  • Loading branch information
jperelli committed Aug 27, 2024
1 parent b2a2fcf commit c375880
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ class Browser {
this.browser = await this.launch();
}
catch (e) {
console.log(e)
console.log('Error opening browser')
console.log(JSON.stringify(e, undefined, 2))
}
Expand Down Expand Up @@ -246,7 +247,7 @@ export default function(options) {
})();
} else {
if (options.oxipng) {
const child = child_process.spawn('/root/.cargo/bin/oxipng', ['-']);
const child = spawn('/root/.cargo/bin/oxipng', ['-o0', '-s', '-']);
child.stdin.on('error', function() {});
child.stdin.write(imageBinary);
child.stdin.end();
Expand Down

0 comments on commit c375880

Please sign in to comment.