Changelog
4.5.3
Adds Twig support to the HTML task.
Basic use: in task-config.js
, set html.templateLanguage
to twig
.
html : {
templateLanguage: 'twig',
},
Advanced use: pass gulp-twig
options in task-config.js
's html.twig
html: {
templateLanguage: 'twig',
twig: {…},
},
Changelog
4.5.2
dataFile
the extension .yaml
or .yml
.Changelog
4.5.1
Users can configure plugins
and options
in task-config.js
's stylesheets.postcss
. See gulp-postcss for more info.
Basic usage is unchanged. Source stylesheets will be preprocessed with Sass unless stylesheets.sass
is false
. You can still call out Sass explicitly if you like:
// in task-config.js
stylesheets: true
A task-config
with custom PostCSS will look like this
// task-config.js
// must also add the dependencies (`(npm i|yarn add) some-plugin some-option`)
var somePlugin = require('some-plugin')
var someOption = require('some-option')
var postCssPlugins = [somePlugin()]
var postCssOptions = {someOption}
module.exports = {
// ...
stylesheets: {
// sass: true is implied
postcss: {
plugins: postCssPlugins,
options: postCssOptions
}
}
// ...
}
Autoprefixer and cssnano are injected into the PostCSS plugins list, and do not need to be specified. However custom Autoprefixer and/or cssnano configs are respected if provided. That looks like this:
// task-config.js
// must also add the autoprefixer dependency (`(npm i|yarn add) autoprefixer`)
var autoprefixer = require('autoprefixer')
var postCssPlugins = [
autoprefixer({
grid: "autoplace"
})
]
module.exports = {
// ...
stylesheets: {
// sass: true is implied
postcss: {
plugins: postCssPlugins
}
}
// ...
}
Changelog
4.5.0
Recommended security-focused upgrade:
es2015
Babel preset is no longer supported in the task-config.js
javascript
task. Replace es2015
with env
. (#573 for more information.)Changelog
4.4.2
Changelog
4.4.1
fancy-log
package does not break tasksChangelog
4.4.0
Changelog
4.3.0
yarn run blendid -- http2-upgrade