We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello! I'm using this plugin to add some data for gulp-swig.
This plugin has a cache for readed files? Why when I changed data files, same content in return like first time?
The text was updated successfully, but these errors were encountered:
I found answer, it's require() cache.
My solution:
gulp.task('json-test', function() { return gulp.src('./examples/test1.html') .pipe(data(function(file) { var json = './examples/' + path.basename(file.path) + '.json'; delete require.cache[require.resolve(json)]; return require(json); })) .pipe(swig()) .pipe(gulp.dest('build')); });
Sorry, something went wrong.
@bolord thanks for coming back and posting your solution, as I was looking a way to clean the cache on gulp-data.
No branches or pull requests
Hello! I'm using this plugin to add some data for gulp-swig.
This plugin has a cache for readed files?
Why when I changed data files, same content in return like first time?
The text was updated successfully, but these errors were encountered: