rollup-plugin-visualizer
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -1057,2 +1057,23 @@ (function () { | ||
function getAncestors(node) { | ||
const parents = []; | ||
while (node != null) { | ||
parents.push(node); | ||
node = node.parent; | ||
} | ||
return parents; | ||
} | ||
function color(node) { | ||
if (node.children && node.children.length) { | ||
const parents = getAncestors(node); | ||
const hasNodeModules = !!parents.find(n => { | ||
return n.data.name === "node_modules"; | ||
}); | ||
return hasNodeModules ? "#599e59" : "#487ea4"; | ||
} else { | ||
return "#db7100"; | ||
} | ||
} | ||
function count$1(node) { | ||
@@ -1556,23 +1577,2 @@ var sum = 0, | ||
function getAncestors(node) { | ||
const parents = []; | ||
while (node != null) { | ||
parents.push(node); | ||
node = node.parent; | ||
} | ||
return parents; | ||
} | ||
function color(node) { | ||
if (node.children && node.children.length) { | ||
const parents = getAncestors(node); | ||
const hasNodeModules = !!parents.find(n => { | ||
return n.data.name === "node_modules"; | ||
}); | ||
return hasNodeModules ? "#599e59" : "#487ea4"; | ||
} else { | ||
return "#db7100"; | ||
} | ||
} | ||
const format$1 = format_1; | ||
@@ -1579,0 +1579,0 @@ |
{ | ||
"name": "rollup-plugin-visualizer", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"main": "plugin.js", | ||
@@ -17,4 +17,4 @@ "author": "Denis Bardadym <bardadymchik@gmail.com>", | ||
"lint": "eslint .", | ||
"build": "cp ./src/*.css ./lib/ && rollup -c rollup.config.js -i ./src/script-sunburst.js -o ./lib/main-sunburst.js && rollup -c rollup.config.js -i ./src/script-treemap.js -o ./lib/main-treemap.js", | ||
"build:dev": "cp ./src/*.css ./lib/ && rollup -c rollup.config-dev.js -i ./src/script-sunburst.js -o ./lib/main-sunburst.js && rollup -c rollup.config-dev.js -i ./src/script-treemap.js -o ./lib/main-treemap.js", | ||
"build": "cp ./src/*.css ./lib/ && rollup -c rollup.config.js -i ./src/script-sunburst.js -o ./lib/main-sunburst.js && rollup -c rollup.config.js -i ./src/script-treemap.js -o ./lib/main-treemap.js && rollup -c rollup.config.js -i ./src/script-circlepacking.js -o ./lib/main-circlepacking.js", | ||
"build:dev": "cp ./src/*.css ./lib/ && rollup -c rollup.config-dev.js -i ./src/script-sunburst.js -o ./lib/main-sunburst.js && rollup -c rollup.config-dev.js -i ./src/script-treemap.js -o ./lib/main-treemap.js && rollup -c rollup.config-dev.js -i ./src/script-circlepacking.js -o ./lib/main-circlepacking.js", | ||
"prepare": "yarn run build", | ||
@@ -21,0 +21,0 @@ "test": "echo \"Error: no test specified\" && exit 0" |
Sorry, the diff of this file is too big to display
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
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
228951
10
6851
0