penthouse-pages
v0.1.5
Published
process multiple pages with penthouse
Downloads
31
Maintainers
Readme
penthouse-pages
Plugin process array of pages through Penthouse which extracts critical path css to increase page speed rendering
Install
npm install penthouse-pages --save-dev
Usage
Can be used with gulp or separately
let gulp = require('gulp');
let penthouse = require('penthouse-pages');
gulp.task('critical-css', ['less'], () => {
return penthouse({
// penthouse-page options
pages: [
{
name: 'index',
url: '',
},
'about',
'about/contacts'
],
baseUrl: 'http://example.com/',
dest: './dest/',
// penthouse options
css: './styles.css',
width: 1300,
height: 900,
strict: true,
});
});
This task will process example.com/
, example.com/about
, example.com/about/contacts
pages and generate ./dest/index.css
, ./dest/about.css
, ./dest/about-contacts.css
files
Licence
MIT © shrpne