Update dependencies.
This commit is contained in:
parent
b20fa133c4
commit
b5ab2776b8
12
package.json
12
package.json
|
|
@ -26,9 +26,9 @@
|
|||
"url": "https://github.com/d3/d3-force.git"
|
||||
},
|
||||
"scripts": {
|
||||
"pretest": "rm -rf build && mkdir build && rollup --banner \"$(preamble)\" -g d3-collection:d3,d3-dispatch:d3,d3-quadtree:d3,d3-timer:d3 -f umd -n d3 -o build/d3-force.js -- index.js",
|
||||
"pretest": "rm -rf build && mkdir build && rollup -c --banner \"$(preamble)\"",
|
||||
"test": "tape 'test/**/*-test.js' && eslint index.js src",
|
||||
"prepublish": "npm run test && uglifyjs --preamble \"$(preamble)\" build/d3-force.js -c -m -o build/d3-force.min.js",
|
||||
"prepare": "npm run test && uglifyjs -b beautify=false,preamble=\"'$(preamble)'\" build/d3-force.js -c -m -o build/d3-force.min.js",
|
||||
"postpublish": "git push && git push --tags && cd ../d3.github.com && git pull && cp ../d3-force/build/d3-force.js d3-force.v1.js && cp ../d3-force/build/d3-force.min.js d3-force.v1.min.js && git add d3-force.v1.js d3-force.v1.min.js && git commit -m \"d3-force ${npm_package_version}\" && git push && cd - && zip -j build/d3-force.zip -- LICENSE README.md build/d3-force.js build/d3-force.min.js"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
@ -38,10 +38,10 @@
|
|||
"d3-timer": "1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"eslint": "3",
|
||||
"package-preamble": "0.0",
|
||||
"rollup": "0.41",
|
||||
"eslint": "4",
|
||||
"package-preamble": "0.1",
|
||||
"rollup": "0.50",
|
||||
"tape": "4",
|
||||
"uglify-js": "^2.8.11"
|
||||
"uglify-js": "3"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
14
rollup.config.js
Normal file
14
rollup.config.js
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
const definition = require("./package.json");
|
||||
const dependencies = Object.keys(definition.dependencies);
|
||||
|
||||
export default {
|
||||
input: "index",
|
||||
external: dependencies,
|
||||
output: {
|
||||
extend: true,
|
||||
file: `build/${definition.name}.js`,
|
||||
format: "umd",
|
||||
globals: dependencies.reduce((p, v) => (p[v] = "d3", p), {}),
|
||||
name: "d3"
|
||||
}
|
||||
};
|
||||
Loading…
Reference in New Issue
Block a user