rollup-watch
Advanced tools
Comparing version 3.2.0 to 3.2.1
# rollup-watch changelog | ||
## 3.2.1 | ||
* Fix missing `require-relative` | ||
## 3.2.0 | ||
@@ -4,0 +8,0 @@ |
@@ -6,6 +6,37 @@ 'use strict'; | ||
var EventEmitter = _interopDefault(require('events')); | ||
var relative = _interopDefault(require('require-relative')); | ||
var path = require('path'); | ||
var path__default = path['default']; | ||
var module$1 = _interopDefault(require('module')); | ||
var fs = require('fs'); | ||
var path$1 = path__default; | ||
var Module = module$1; | ||
var modules = {}; | ||
var getModule = function(dir) { | ||
var rootPath = dir ? path$1.resolve(dir) : process.cwd(); | ||
var rootName = path$1.join(rootPath, '@root'); | ||
var root = modules[rootName]; | ||
if (!root) { | ||
root = new Module(rootName); | ||
root.filename = rootName; | ||
root.paths = Module._nodeModulePaths(rootPath); | ||
modules[rootName] = root; | ||
} | ||
return root; | ||
}; | ||
var requireRelative = function(requested, relativeTo) { | ||
var root = getModule(relativeTo); | ||
return root.require(requested); | ||
}; | ||
requireRelative.resolve = function(requested, relativeTo) { | ||
var root = getModule(relativeTo); | ||
return Module._resolveFilename(requested, root); | ||
}; | ||
var index$1 = requireRelative; | ||
function sequence ( array, fn ) { | ||
@@ -31,3 +62,3 @@ let results = []; | ||
try { | ||
chokidar = relative( 'chokidar', process.cwd() ); | ||
chokidar = index$1( 'chokidar', process.cwd() ); | ||
} catch (err) { | ||
@@ -34,0 +65,0 @@ chokidar = null; |
import EventEmitter from 'events'; | ||
import relative from 'require-relative'; | ||
import { resolve } from 'path'; | ||
import path__default from 'path'; | ||
import * as path from 'path'; | ||
import module$1 from 'module'; | ||
import { readFileSync, realpathSync, watch } from 'fs'; | ||
import * as fs from 'fs'; | ||
var path$1 = path__default; | ||
var Module = module$1; | ||
var modules = {}; | ||
var getModule = function(dir) { | ||
var rootPath = dir ? path$1.resolve(dir) : process.cwd(); | ||
var rootName = path$1.join(rootPath, '@root'); | ||
var root = modules[rootName]; | ||
if (!root) { | ||
root = new Module(rootName); | ||
root.filename = rootName; | ||
root.paths = Module._nodeModulePaths(rootPath); | ||
modules[rootName] = root; | ||
} | ||
return root; | ||
}; | ||
var requireRelative = function(requested, relativeTo) { | ||
var root = getModule(relativeTo); | ||
return root.require(requested); | ||
}; | ||
requireRelative.resolve = function(requested, relativeTo) { | ||
var root = getModule(relativeTo); | ||
return Module._resolveFilename(requested, root); | ||
}; | ||
var index$1 = requireRelative; | ||
function sequence ( array, fn ) { | ||
@@ -28,3 +59,3 @@ let results = []; | ||
try { | ||
chokidar = relative( 'chokidar', process.cwd() ); | ||
chokidar = index$1( 'chokidar', process.cwd() ); | ||
} catch (err) { | ||
@@ -31,0 +62,0 @@ chokidar = null; |
{ | ||
"name": "rollup-watch", | ||
"version": "3.2.0", | ||
"version": "3.2.1", | ||
"description": "Watch files for changes and perform incremental rebuilds with Rollup", | ||
@@ -31,2 +31,5 @@ "main": "dist/rollup-watch.cjs.js", | ||
"homepage": "https://github.com/rollup/rollup-watch#readme", | ||
"dependencies": { | ||
}, | ||
"devDependencies": { | ||
@@ -33,0 +36,0 @@ "eslint": "^3.12.2", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16250
7
498