gulp-web/README.md

42 lines
709 B
Markdown

## Build Directory
Default build directory is `./build`. To change edit `gulpfile.js`.
## Features
* JS transpilation, minification with Babel, Terser.
* SASS compilation, css minification.
* HTML file includes.
* Mustache templating
* SVG optimisation.
* BrowserSync.
### TODO
* Image optomisation.
## Usage
### HTML File Includes
Uses [gulp-file-include - npm](https://www.npmjs.com/package/gulp-file-include).
Include file with:
```
@@include('./logo.svg')
```
Files are relative to the include directory: `src/includes/`.
### Mustache Templates
Include a template with:
```
{{> templates/example}}
```
Templates are relative to the HTML file and the `.mustache` extension must be
ommitted.