Compile LESS with Grunt
The topic describes how to install, configure and use Grunt JavaScript task runner for compiling .less
files in Magento 2.
Prerequisites
- Node.js (LTS version are recommended)
grunt-cli
package instaled globaly
Installing and configuring Grunt
- Rename
Gruntfile.js.sample
toGruntfile.js
- Rename
package.json.sample
topackage.json
- Install dependecies
npm install
oryarn
- Add you theme to config file
dev/tools/grunt/configs/themes.js
- Complie styles using
gulp less:<theme>
There are more tasks avalivable, but... it's slow, not maintained and overcomplicated.