Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gulp-hashify

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-hashify - npm Package Compare versions

Comparing version 0.0.24 to 0.0.25

2

package.json
{
"name": "gulp-hashify",
"version": "0.0.24",
"version": "0.0.25",
"description": "A gulp plugin for turning a stream of files into a JavaScript object.",

@@ -5,0 +5,0 @@ "main": "hashify.js",

@@ -86,2 +86,30 @@ # gulp-hashify

### Browserify example
This task will find all `.html` files in `./src/views` and bundle them into an external browserify bundle. The
views object can then be imported via `var views = require('views');`, provided `./dist/js/views.js` is referred
to in the HTML file.
```javascript
var gulp = require('gulp');
var browserify = require('browserify');
var hashify = require('gulp-hashify');
var source = require('vinyl-source-stream');
var buffer = require('vinyl-buffer');
var tap = require('gulp-tap');
gulp.task('js:views', function () {
return gulp.src('./src/views/**/*.html')
.pipe(hashify('bundled-views.js'))
.pipe(tap(function(file) {
return browserify()
.require(file, { expose: 'views' })
.bundle()
.pipe(source('views.js'))
.pipe(buffer())
.pipe(gulp.dest('./dist/js'));
}));
});
```
---

@@ -97,2 +125,2 @@

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc