UXP Toolkit
    Preparing search index...

    Options for saving a document in PNG format using the Document.saveAs method

    const doc = app.activeDocument;
    const saveFile = await require('uxp').storage.localFileSystem.getFileForSaving("image.png");
    await doc.saveAs.png(saveFile, {
    compression: 6,
    interlaced: false
    });

    objects/saveoptions

    22.5

    interface PNGSaveOptions {
        compression?: number;
        interlaced?: boolean;
        method?: PNGMethod;
    }
    Index

    Properties

    compression?: number

    The compression value to be used when method = PNGMethod.QUICK

    0...9

    6
    

    22.5

    interlaced?: boolean

    True to interlace rows when method = PNGMethod.QUICK

    false
    

    22.5

    method?: PNGMethod

    PNG File Size optimization method.

    22.5