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

watchr

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

watchr - npm Package Compare versions

Comparing version 2.1.1 to 2.1.2

2

out/bin/watchr.js

@@ -23,3 +23,3 @@ // Generated by CoffeeScript 1.3.3

},
next: function(err, wachter) {
next: function(err, watcher) {
if (err) {

@@ -26,0 +26,0 @@ throw err;

@@ -53,3 +53,3 @@ // Generated by CoffeeScript 1.3.3

function _Class(config, next) {
var applyStat, listener, watcher, _i, _len, _ref, _ref1,
var applyStat, listener, watcher, _base, _base1, _base2, _base3, _i, _len, _ref, _ref1, _ref2, _ref3, _ref4, _ref5,
_this = this;

@@ -68,2 +68,14 @@ _ref = balUtil.extractOptsAndCallback(config, next), config = _ref[0], next = _ref[1];

this.config = config;
if ((_ref1 = (_base = this.config).ignoreHiddenFiles) == null) {
_base.ignoreHiddenFiles = false;
}
if ((_ref2 = (_base1 = this.config).ignorePatterns) == null) {
_base1.ignorePatterns = false;
}
if ((_ref3 = (_base2 = this.config).interval) == null) {
_base2.interval = 100;
}
if ((_ref4 = (_base3 = this.config).persistent) == null) {
_base3.persistent = true;
}
if (config.listener) {

@@ -73,5 +85,5 @@ this.listen(config.listener);

if (config.listeners) {
_ref1 = config.listeners;
for (_i = 0, _len = _ref1.length; _i < _len; _i++) {
listener = _ref1[_i];
_ref5 = config.listeners;
for (_i = 0, _len = _ref5.length; _i < _len; _i++) {
listener = _ref5[_i];
this.listen(listener);

@@ -291,3 +303,3 @@ }

startWatching = function() {
var tasks, watchFileOpts, _ref, _ref1;
var tasks, watchFileOpts;
tasks = new balUtil.Group(function(err) {

@@ -317,4 +329,4 @@ return typeof next === "function" ? next(err) : void 0;

watchFileOpts = {
persistant: (_ref = config.persistant) != null ? _ref : true,
interval: (_ref1 = config.interval) != null ? _ref1 : 100
persistent: config.persistent,
interval: config.interval
};

@@ -321,0 +333,0 @@ fsUtil.watchFile(_this.path, watchFileOpts, function() {

{
"name": "watchr",
"version": "2.1.1",
"description": "Provides a better and normalised API between Node's 0.4 watchFile and 0.6's fsWatcher",
"version": "2.1.2",
"description": "Better file system watching for Node.js",
"homepage": "https://github.com/bevry/watchr",

@@ -10,3 +10,4 @@ "keywords": [

"fswatcher",
"watchfile"
"watchfile",
"fs"
],

@@ -13,0 +14,0 @@ "author": "Bevry Pty Ltd <us@bevry.me> (http://bevry.me)",

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