refactor(tasks): add postinstall

This commit is contained in:
moklick
2019-07-15 17:02:18 +02:00
parent cf4441ce6d
commit 1c382a799d
3 changed files with 28 additions and 7 deletions

18
package-lock.json generated
View File

@@ -1,5 +1,5 @@
{
"name": "react-graph",
"name": "react-graphs",
"version": "1.0.0",
"lockfileVersion": 1,
"requires": true,
@@ -6564,6 +6564,22 @@
"prop-types": "^15.6.0"
}
},
"react-graph": {
"version": "git+ssh://git@github.com/wbkd/react-graph.git#cf4441ce6d43385a4a3dddececcc705bb17ff093",
"from": "git+ssh://git@github.com/wbkd/react-graph.git",
"requires": {
"@emotion/core": "^10.0.14",
"@emotion/styled": "^10.0.14",
"d3-selection": "^1.4.0",
"d3-zoom": "^1.7.3",
"lodash.isequal": "^4.5.0",
"ms": "^2.0.0",
"prop-types": "^15.7.2",
"react": "^16.8.6",
"react-draggable": "^3.3.0",
"react-sizeme": "^2.6.7"
}
},
"react-is": {
"version": "16.8.6",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.8.6.tgz",

View File

@@ -1,5 +1,5 @@
{
"name": "react-graph",
"name": "react-graphs",
"version": "1.0.0",
"module": "dist/ReactGraph.esm.js",
"browser": "dist/ReactGraph.umd.js",
@@ -10,10 +10,8 @@
"d3-selection": "^1.4.0",
"d3-zoom": "^1.7.3",
"lodash.isequal": "^4.5.0",
"ms": "^2.0.0",
"prop-types": "^15.7.2",
"react": "^16.8.6",
"react-draggable": "^3.3.0",
"react-graph": "git+ssh://git@github.com/wbkd/react-graph.git",
"react-sizeme": "^2.6.7"
},
"devDependencies": {
@@ -30,10 +28,16 @@
"rollup-plugin-node-resolve": "^5.1.0",
"rollup-plugin-serve": "^1.0.1"
},
"peerDependencies": {
"react": "^16.0.0",
"prop-types": "^15.0.0-0"
},
"scripts": {
"build": "rollup -c",
"watch": "rollup -w -c",
"dev": "parcel example/index.html -d example/build"
"dev": "parcel example/index.html -d example/build",
"prepublish": "npm run build",
"postinstall": "npm run build"
},
"files": [
"dist"

View File

@@ -6,7 +6,7 @@ import pkg from './package.json';
export default [{
input: 'src/index.js',
external: ['react'],
external: ['react', 'prop-types'],
output: {
name: 'ReactGraph',
file: pkg.browser,
@@ -14,6 +14,7 @@ export default [{
sourcemaps: true,
globals: {
react: 'React',
'prop-types': 'PropTypes'
}
},
plugins: [