diff --git a/plugins/layout/example/index.jsx b/plugins/layout/example/index.jsx index 8eb1572b..757cedba 100644 --- a/plugins/layout/example/index.jsx +++ b/plugins/layout/example/index.jsx @@ -1,6 +1,6 @@ import React from 'react'; import ReactDOM from 'react-dom'; -import App from './src/app1.jsx'; +import App from './src/app.jsx'; ReactDOM.render(( diff --git a/plugins/layout/example/package.json b/plugins/layout/example/package.json index ea1f5cfb..9abc2ba8 100644 --- a/plugins/layout/example/package.json +++ b/plugins/layout/example/package.json @@ -8,7 +8,7 @@ "author": "sdjalft", "license": "MIT", "dependencies": { - "butterfly-plugins-layout": "^0.0.14", + "butterfly-plugins-layout": "^0.0.15", "jquery": "^3.6.0", "react": "^16.12.0", "react-dom": "^16.12.0" diff --git a/plugins/layout/example/src/app.jsx b/plugins/layout/example/src/app.jsx index c293c6ee..30f53cf2 100644 --- a/plugins/layout/example/src/app.jsx +++ b/plugins/layout/example/src/app.jsx @@ -5,7 +5,7 @@ import './app.less'; import '../../../../static/butterfly.css'; const treeData = require('./mock_data.json'); import {GraphvizEdge} from 'butterfly-plugins-layout/graphvizLayout'; -import {graphvizLayout} from '../../dist/app'; +import {graphvizLayout} from 'butterfly-plugins-layout'; // const {graphvizLayout} = require('../../index'); class BaseNode extends Node { diff --git a/plugins/layout/package.json b/plugins/layout/package.json index 5240cc82..32f3ea73 100644 --- a/plugins/layout/package.json +++ b/plugins/layout/package.json @@ -1,6 +1,6 @@ { "name": "butterfly-plugins-layout", - "version": "0.0.14", + "version": "0.0.15", "description": "butterfly-plugins-layout,含有各种布局函数", "main": "dist/index.js", "module": "dist/index.es.js", @@ -25,10 +25,25 @@ "devDependencies": { "@babel/core": "^7.12.10", "@babel/plugin-proposal-class-properties": "^7.12.1", + "@babel/plugin-proposal-object-rest-spread": "^7.18.6", "@babel/plugin-transform-runtime": "^7.12.10", "@babel/preset-env": "^7.12.11", + "@babel/preset-react": "^7.18.6", + "@babel/runtime": "^7.18.6", "@rollup/plugin-babel": "^5.2.2", - "rollup": "^2.36.1", - "rollup-plugin-commonjs": "^10.1.0" + "babel-loader": "^8.2.5", + "babel-plugin-transform-es2015-modules-commonjs": "^6.26.2", + "css-loader": "^1.0.1", + "html-webpack-plugin": "^5.5.0", + "less": "^3.13.1", + "less-loader": "^4.1.0", + "mini-css-extract-plugin": "^2.6.1", + "rollup": "~2.56.2", + "rollup-plugin-commonjs": "^10.1.0", + "rollup-plugin-postcss": "^3.1.8", + "style-loader": "^0.21.0", + "webpack": "^5.73.0", + "webpack-cli": "^4.10.0", + "webpack-dev-server": "^4.9.3" } } diff --git a/plugins/layout/rollup.config.js b/plugins/layout/rollup.config.js index e1d08a65..845eab56 100644 --- a/plugins/layout/rollup.config.js +++ b/plugins/layout/rollup.config.js @@ -16,7 +16,6 @@ if (!fs.existsSync(dist)) { } const plugins = [ - commonjs(), babel( { exclude: 'node_modules/**', @@ -38,6 +37,7 @@ const plugins = [ ] ] }), + commonjs(), ]; const main = {