jellies-draw 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,14 +1,15 @@
1
1
  {
2
2
  "name": "jellies-draw",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "A drawer for jellies",
5
5
  "private": false,
6
6
  "main": "./src/index.js",
7
7
  "scripts": {
8
8
  "serve": "vue-cli-service serve",
9
- "build": "webpack --display-error-details --config webpack.config.js",
9
+ "build": "webpack --mode=production --config webpack.config.js",
10
10
  "lint": "vue-cli-service lint"
11
11
  },
12
+ "license": "MIT",
12
13
  "files": [
13
14
  "src/*",
14
15
  "package",
@@ -19,29 +20,26 @@
19
20
  "dependencies": {
20
21
  "core-js": "^3.6.5",
21
22
  "konva": "^9.0.1",
22
- "vue": "^2.6.11"
23
+ "vue": "^2.7.0"
23
24
  },
24
25
  "devDependencies": {
25
- "@vue/cli-plugin-babel": "^4.1.1",
26
- "@vue/cli-plugin-eslint": "^4.1.1",
27
- "@vue/cli-service": "^4.1.1",
28
- "babel-eslint": "^10.1.0",
29
- "eslint": "^6.7.2",
30
- "eslint-plugin-vue": "^6.2.2",
31
- "babel-core": "^6.26.3",
32
- "babel-loader": "^7.1.5",
33
- "css-loader": "^0.28.7",
34
- "less": "^2.7.3",
35
- "less-loader": "^4.0.5",
36
- "sass": "^1.26.5",
37
- "sass-loader": "^7.3.1",
38
- "style-loader": "^0.19.0",
39
- "url-loader": "^0.6.2",
40
- "vue": "^2.5.9",
41
- "vue-loader": "^13.5.0",
42
- "vue-style-loader": "^3.0.3",
43
- "vue-template-compiler": "^2.5.9",
44
- "webpack": "^3.9.1"
26
+ "@babel/core": "^7.21.8",
27
+ "@babel/eslint-parser": "^7.12.16",
28
+ "@babel/preset-env": "^7.21.5",
29
+ "@vue/cli-plugin-babel": "~5.0.8",
30
+ "@vue/cli-plugin-eslint": "~5.0.8",
31
+ "@vue/cli-service": "~5.0.8",
32
+ "babel-loader": "^9.1.2",
33
+ "css-loader": "^6.0.0",
34
+ "eslint": "^7.32.0",
35
+ "eslint-plugin-vue": "^8.0.3",
36
+ "style-loader": "^3.3.2",
37
+ "url-loader": "^4.1.1",
38
+ "vue-loader": "^15.1.0",
39
+ "vue-style-loader": "^4.1.3",
40
+ "vue-template-compiler": "^2.7.14",
41
+ "webpack": "^5.81.0",
42
+ "webpack-cli": "^5.1.0"
45
43
  },
46
44
  "eslintConfig": {
47
45
  "root": true,
@@ -53,7 +51,7 @@
53
51
  "eslint:recommended"
54
52
  ],
55
53
  "parserOptions": {
56
- "parser": "babel-eslint"
54
+ "parser": "@babel/eslint-parser"
57
55
  },
58
56
  "rules": {}
59
57
  },
package/src/index.js CHANGED
@@ -2,7 +2,7 @@ import DrawingCanvas from './components/DrawingCanvas.vue'
2
2
  import ToolButtons from './components/ToolButtons.vue'
3
3
  import PropertyPickers from './components/PropertyPickers.vue'
4
4
 
5
- export default {
5
+ export {
6
6
  DrawingCanvas,
7
7
  PropertyPickers,
8
8
  ToolButtons
package/webpack.config.js CHANGED
@@ -1,39 +1,52 @@
1
1
  const path = require("path");
2
+ const { VueLoaderPlugin } = require('vue-loader')
2
3
  module.exports = {
3
- entry: "./src/index.js",//入口文件
4
- output: {
5
- path: path.resolve(__dirname, './dist'),//输出路径
6
- publicPath: '/dist/',
7
- filename: 'jellies-draw.js',
8
- libraryTarget: 'umd',
9
- umdNamedDefine: true
10
- },
11
- module: {
12
- rules: [{
13
- test: /\.vue$/,
14
- loader: 'vue-loader'
15
- },
16
- {
17
- test: /\.(less|css)$/,
18
- use: [
19
- { loader: "style-loader" },
20
- { loader: "css-loader" },
21
- { loader: "less-loader" }
22
- ]
23
- },
24
- {
25
- test: /\.js$/,
26
- exclude: /node_modules|vue\/dist|vue-router\/|vue-loader\/|vue-hot-reload-api\//,
27
- loader: 'babel-loader'
28
- },
29
- {
30
- test: /\.(png|jpg|gif|ttf|svg|woff|woff2|eot)$/,
31
- loader: 'url-loader',
32
- query: {
33
- limit: 30000,
34
- name: '[name].[ext]?[hash]'
35
- }
36
- }
4
+ entry: "./src/index.js",//入口文件
5
+ output: {
6
+ path: path.resolve(__dirname, './dist'),//输出路径
7
+ publicPath: '/dist/',
8
+ filename: 'jellies-draw.js',
9
+ libraryTarget: 'umd',
10
+ umdNamedDefine: true
11
+ },
12
+ plugins: [
13
+ new VueLoaderPlugin()
14
+ ],
15
+ module: {
16
+ rules: [{
17
+ test: /\.vue$/,
18
+ loader: 'vue-loader'
19
+ },
20
+ {
21
+ test: /\.(css)$/,
22
+ use: [
23
+ 'vue-style-loader',
24
+ { loader: "style-loader" },
25
+ { loader: "css-loader" }
37
26
  ]
38
- },
27
+ },
28
+ {
29
+ test: /\.js$/,
30
+ exclude: /node_modules/,
31
+ use: {
32
+ loader: 'babel-loader',
33
+ options: {
34
+ presets: ['@babel/preset-env'],
35
+ },
36
+ }
37
+ },
38
+ {
39
+ test: /\.(png|jpg|gif|ttf|svg|woff|woff2|eot)$/,
40
+ loader: 'url-loader',
41
+ parser: {
42
+ dataUrlCondition: {
43
+ maxSize: 30 * 1024 // 30kb
44
+ }
45
+ },
46
+ generator: {
47
+ filename: 'assets/[name].[contenthash:8][ext]'
48
+ }
49
+ }
50
+ ]
51
+ },
39
52
  }