Nuked: Probably Microwaved
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    datauri-dimensionspublic

    datauri-dimensions

    Parse the dimensions of a data URI png / jpeg

    Installation

    $ component install component/datauri-dimensions
    

    Example

    var size = require('datauri-dimensions');
     
    var canvas = document.createElement('canvas');
    canvas.width = 100;
    canvas.height = 150;
     
    var uri = canvas.toDataURL('image/jpeg');
    console.log(size(uri));
     
    var uri = canvas.toDataURL('image/png');
    console.log(size(uri));

    License

    MIT

    Keywords

    none

    install

    npm i datauri-dimensions

    Downloadsweekly downloads

    13

    version

    0.0.1

    license

    none

    last publish

    collaborators

    • avatar