node package manager
Easy collaboration. Discover, share, and reuse code in your team. Create a free org »



npm version badge Build Status License

Grunt task for Polyfiller

Getting Started

This plugin requires Grunt ~0.4.5

If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:

npm install grunt-polyfiller --save-dev

Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:


grunt-polyfiller task

Run this task with the grunt polyfiller command.

Task targets, files and options may be specified according to the grunt Configuring tasks guide.

Usage Example

module.exports = function (grunt) {
        polyfiller: {
            build: {
                options: {
                    features: ['Promise', 'Fetch']
                dest: 'polyfills.js'
    grunt.registerTask('default', ['polyfiller']);


Type: Object.

All of options are the options for the Polyfiller itself, except these ones:


Type: Function(Object:feature, String:name, Array:features)

This option as an advanced way to control the file contents that are created.

options: {
    process: function (feature, name, features) {
        return feature.source;

For more details see the Polyfiller documentation


grunt test



Task submitted by Alexander Abashkin