1.4.0 • Published 3 years ago

snapify v1.4.0

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

snapify

take beautiful page screenshots

install

yarn add snapify

usage

const snap = require('./snapify');
(async () => {
  await snap('https://apple.com', {
    viewports: ['iPad Pro'],
    fullPage: true,
    style: {
      filter: 'grayscale(100%)'
    }
  });
})();

npm.io

features

✅ plug and play
✅ element screenshots
✅ custom css styles
✅ custom pre-snap script
✅ supports all chrome emulated devices and their orientation
✅ supports lazy loaded content by scrolling the page
✅ uses puppeteer-cluster for concurrenct screenshots

api

async snap(url: string, options?: SnapifyOptions): Promise<Array<Buffer>>;

options

name

string

location

string

viewports

[{width, height}, 'emulatedDevice']

style

string

script

string

fullPage

boolean

scroll

boolean

persist

boolean

1.4.0

3 years ago

1.3.1

3 years ago

1.3.0

3 years ago

1.2.1

3 years ago

1.2.0

3 years ago

1.1.1

3 years ago

1.0.2

3 years ago

1.1.0

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago