1. gulp-cache-bust
Append a query string to your assets to bust that cache!
gulp-cache-bust
Package: gulp-cache-bust
Created by: furzeface
Last modified: Sat, 18 Jun 2022 16:43:04 GMT
Version: 1.4.1
License: MIT
Downloads: 13,203
Repository: https://github.com/furzeface/gulp-cache-bust

Install

npm install gulp-cache-bust
yarn add gulp-cache-bust

gulp-cache-bust

NPM version Build Status Coverage Status Dependency Status

cachebust plugin for gulp

Usage

First, install gulp-cache-bust as a development dependency:

 npm install --save-dev gulp-cache-bust

Then, add it to your gulpfile.js:

 var cachebust = require('gulp-cache-bust');

gulp.src('./dist/*/*.html')
	.pipe(cachebust({
		type: 'timestamp'
	}))
	.pipe(gulp.dest('./dist'));

API

cache-bust(options)

options.type

Type: String
Default: MD5

The time of query string you want appended to your asset URLs.

options.basePath

Type: String
Default: ''

Path to find File in case you chose the MD5 Type of cache-busting.

License

Copyright (c) 2014 Daniel Furze.

Licensed under the MIT license: http://danielfurze.mit-license.org

RELATED POST

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin