https://github.com/redturtle/grunt-blocks
Grunt configuration helper for Plone add-ons and themes
https://github.com/redturtle/grunt-blocks
config configuration grunt grunt-configuration javascript
Last synced: about 2 months ago
JSON representation
Grunt configuration helper for Plone add-ons and themes
- Host: GitHub
- URL: https://github.com/redturtle/grunt-blocks
- Owner: RedTurtle
- License: mit
- Created: 2018-06-07T07:37:08.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T01:24:07.000Z (over 2 years ago)
- Last Synced: 2025-03-09T22:02:28.235Z (3 months ago)
- Topics: config, configuration, grunt, grunt-configuration, javascript
- Language: TypeScript
- Size: 498 KB
- Stars: 1
- Watchers: 11
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES.md
- License: LICENSE
Awesome Lists containing this project
README
# grunt-blocks
Grunt configuration helper for Plone add-ons and themes
## Usage
Example `Gruntfile.js`:
```javascript
const blocks = require('@redturtle/grunt-blocks').default;module.exports = function(grunt) {
'use strict';
require('load-grunt-tasks')(grunt);
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
sass: {
options: blocks.sass.options(['./optional/sass/include/path']),
main: blocks.sass.file('theme'),
backend: blocks.sass.file('theme.backend'),
},
postcss: {
prefix_main: blocks.postcss.prefix('theme'),
prefix_be: blocks.postcss.prefix('theme.backend'),
min_main: blocks.postcss.cssmin('theme'),
min_be: blocks.postcss.cssmin('theme.backend'),
},
});grunt.registerTask('compile', ['sass', 'postcss']);
grunt.registerTask('main', [
'sass:main',
'postcss:prefix_main',
'postcss:min_main',
]);
grunt.registerTask('be', [
'sass:backend',
'postcss:prefix_be',
'postcss:min_be',
]);
};
```## Installation
```bash
# npm
npm install --save-dev @redturtle/grunt-blocks# or yarn
yarn add --dev @redturtle/grunt-blocks
```