Giter VIP home page Giter VIP logo

gulp-cordova-icon's Introduction

gulp-cordova-icon

Generates all the icons for your Cordova build automatically

Installation

npm install --save-dev gulp-cordova-icon

This library depends on GraphicsMagick or ImageMagick, so be sure to install one of those.

Usage

const create = require('gulp-cordova-create'),
const icon = require('gulp-cordova-icon'),
const android = require('gulp-cordova-android');

gulp.task('build', () => {
    return gulp.src('dist')
        .pipe(create())
        .pipe(icon('res/my-icon.png'))
        .pipe(android())
        .pipe(gulp.dest('build'));
});

When the project is build for a platform, the icon provided will be used as application icon. It will generate all the different sizes of the icon and puts them in the correct location.

API

icon(file [, options])

file

Type: string

The path to the png or svg icon that will be used as application icon.

options

Type: object

errorHandlingStrategy

Type: string
Defaults to : lenient

The error handling strategy of the process. This field has 3 possible values:

  • lenient (default): any encountered error is silently discarded and the build continues
  • warn: any encountered error is logged as a warning on the console
  • throw: any encountered error is thrown and interrupts the Gulp stream

Related

See gulp-cordova for the full list of available packages.

License

MIT © Sam Verschueren

gulp-cordova-icon's People

Contributors

samverschueren avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.