PHPackages                             magekey/grunt-sprite - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. magekey/grunt-sprite

ActiveMagento2-component[Utility &amp; Helpers](/categories/utility)

magekey/grunt-sprite
====================

Magento2 grunt sprite generation tool

1.1.3(8y ago)28.9k↓50%2MITHTML

Since Dec 4Pushed 8y ago1 watchersCompare

[ Source](https://github.com/magekey/magento2-grunt-sprite)[ Packagist](https://packagist.org/packages/magekey/grunt-sprite)[ RSS](/packages/magekey-grunt-sprite/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (4)Used By (0)

[![Travis branch](https://camo.githubusercontent.com/ea385040915876700a7d600d9ea6062b124a9230a1ca125a2e9d7b03d5861ab5/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6d6167656b65792f6d6167656e746f322d6772756e742d7370726974652f6d61737465722e737667)](https://travis-ci.org/magekey/magento2-grunt-sprite) [![Packagist](https://camo.githubusercontent.com/6be62fe781ad12d8c6726317d8d13f3b9b4fd81453b88e1e81ce484bad68773e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d6167656b65792f6772756e742d7370726974652e737667)](https://packagist.org/packages/magekey/grunt-sprite) [![Packagist](https://camo.githubusercontent.com/a929728f4e0dbedd484609b53496448799da7e9b3fa87787d7e83bc862d1bece/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d6167656b65792f6772756e742d7370726974652e737667)](https://packagist.org/packages/magekey/grunt-sprite)

Magento 2 Grunt Sprite Tool
===========================

[](#magento-2-grunt-sprite-tool)

Sprite Generation for Magento 2, based on Grunt

Installation
------------

[](#installation)

1. Run `composer require magekey/grunt-sprite`
2. Go to package directory `cd vendor/magekey/grunt-sprite`
3. Run `npm install`
4. Run `grunt setup` create a convenient symlink `grunt-sprite` and config file `grunt-sprite-config.json.sample` in the project root.
5. Rename `grunt-sprite-config.json.sample` to `grunt-sprite-config.json` and define your themes

LESS Example:

```
{
  "path": {
    "sprite_mytheme": "/app/design/frontend/Vendor/mytheme/web"
  },
  "sprite": {
    "mytheme": {
      "src": "/images/sprite/*.png",
      "dest": "/images/sprite.png",
      "destCss": "/css/source/_sprite.less"
    }
  }
}

```

SCSS Example:

```
{
  "path": {
    "sprite_mymodule": "/app/design/frontend/Vendor/mytheme"
  },
  "sprite": {
    "test_module": {
      "src": "/MyPackage_Module/web/images/sprite/*.png",
      "dest": "/MyPackage_Module/web/images/sprite.png",
      "destCss": "/MyPackage_Module/web/scss/_sprite.scss",
      "cssTemplate": "/templates/scss.template.handlebars"
    }
  }
}

```

Usage
-----

[](#usage)

```
cd grunt-sprite
grunt sprite:

```

Add sprites to your theme in *app/design/Vendor/theme/web/css/\_styles.less*

```
@import 'source/lib/_lib.less'; // Global lib
@import 'source/_sources.less'; // Theme styles
@import 'source/_components.less'; // Components styles (modal/sliding panel)

// Add new line to import sprites
@import 'source/_sprite.less'; // Sprites

```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~61 days

Total

3

Last Release

2965d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d1933481d3a52c39dee490d9994a360c560405378621591da69520f994595a9e?d=identicon)[magekey](/maintainers/magekey)

---

Top Contributors

[![magekey](https://avatars.githubusercontent.com/u/24832146?v=4)](https://github.com/magekey "magekey (41 commits)")

### Embed Badge

![Health badge](/badges/magekey-grunt-sprite/health.svg)

```
[![Health](https://phpackages.com/badges/magekey-grunt-sprite/health.svg)](https://phpackages.com/packages/magekey-grunt-sprite)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
