0.19.0 • Published 1 year ago

@hidoo/gulp-plugin-image-placeholder v0.19.0

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

@hidoo/gulp-plugin-image-placeholder

Plugin that add image of placeholder for gulp.

Installation

$ npm install --save-dev gulp@next @hidoo/gulp-plugin-image-placeholder

Usage

import { src, dest, task } from 'gulp';
import imagePlaceholder from '@hidoo/gulp-plugin-image-placeholder';

task('placeholder', () =>
  src('/path/to/src').pipe(imagePlaceholder()).pipe(dest('/path/to/dest'))
);

Supported formats

  • PNG
  • JPEG
  • GIF
  • SVG

API

imagePlaceholder

return placeholder image.

Parameters

  • options Object option (optional, default {})

    • options.append Boolean append placeholder or not (optional, default true)
    • options.suffix String placeholder image suffix (optional, default 'placeholder')
    • options.verbose Boolean out log or not (optional, default false)

Examples

import { src, dest, task } from 'gulp';
import imagePlaceholder from '@hidoo/gulp-plugin-image-placeholder';

task('placeholder', () =>
  src('/path/to/src')
    .pipe(
      imagePlaceholder({
        append: false,
        suffix: 'placehold',
        verbose: true
      })
    )
    .pipe(dest('/path/to/dest'))
);

Returns DestroyableTransform

Test

$ pnpm test

License

MIT

1.0.0-alpha.1

1 year ago

1.0.0-alpha.0

1 year ago

0.19.0

4 years ago

0.18.0

4 years ago

0.17.0

4 years ago

0.16.0

4 years ago

0.15.0

5 years ago

0.14.1

6 years ago

0.14.0

6 years ago

0.13.0

6 years ago

0.12.0

6 years ago

0.11.0

6 years ago

0.10.0

6 years ago

0.9.0

6 years ago

0.8.4

6 years ago

0.8.3

6 years ago

0.8.2

6 years ago

0.8.1

6 years ago

0.8.0

7 years ago

0.7.0

7 years ago

0.6.2

7 years ago

0.6.1

7 years ago

0.6.0

7 years ago