This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

phantastic

0.1.3 • Public • Published

phantastic

get a list of website resources via phantomjs

install

npm install phantastic

usage example

var phantastic = require("phantastic")({
    cache: {
        // see https://npmjs.com/package/lru-files
        dir: "/path/to/cache/dir",
        files: 100,
        size: "1 GB",
        age: "1 Day"
    }
});
 
// fetch single site
phantastic.fetch("https://www.example.com/", function(err, data){
    if (err) return console.log(err);
    console.log(data);
});

data

data is an array of resource object. they look like this

[{
    url: 'https://www.example.org/resource',
    domain: 'www.example.org',
    size: 2440,
    time: 87,
    content: 'mime/type',
    cookies: [{
        name: "Some-Cookie",
        size: 1024,
        valid: 356
    }]
}]

Dependencies (8)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i phantastic

    Weekly Downloads

    0

    Version

    0.1.3

    License

    Public Domain

    Last publish

    Collaborators

    • yetzt