Skip to content

Commit

Permalink
chore: updated deps
Browse files Browse the repository at this point in the history
  • Loading branch information
kn0wn committed Sep 21, 2020
1 parent 73a53ca commit 64d6f95
Show file tree
Hide file tree
Showing 11 changed files with 1,861 additions and 1,675 deletions.
8 changes: 4 additions & 4 deletions build/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ export default {
format: "umd",
name: "VueCosha",
exports: "named",
file: "dist/vue-cosha.js"
file: "dist/vue-cosha.js",
},
{
format: "esm",
file: "dist/vue-cosha.esm.js"
}
]
file: "dist/vue-cosha.esm.js",
},
],
};
4 changes: 2 additions & 2 deletions build/rollup.config.min.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ export default {
format: "umd",
name: "VueCosha",
exports: "named",
file: "dist/vue-cosha.min.js"
}
file: "dist/vue-cosha.min.js",
},
};
30 changes: 16 additions & 14 deletions build/webpack.config.js
Original file line number Diff line number Diff line change
@@ -1,50 +1,52 @@
const path = require('path')
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const HtmlWebpackPlugin = require('html-webpack-plugin')
const path = require("path");
const VueLoaderPlugin = require("vue-loader/lib/plugin");
const HtmlWebpackPlugin = require("html-webpack-plugin");

module.exports = {
entry: {
index: path.resolve(__dirname, '../src/main.js'),
index: path.resolve(__dirname, "../src/main.js"),
},
output: {
path: path.resolve(__dirname, './dist'),
filename: 'demo.min.js',
path: path.resolve(__dirname, "./dist"),
filename: "demo.min.js",
},
module: {
rules: [
{
test: /\.vue$/,
loader: 'vue-loader',
loader: "vue-loader",
},
{
test: /\.css$/,
use: ['vue-style-loader', 'css-loader'],
use: ["vue-style-loader", "css-loader"],
},
{
test: /\.(png|jpe?g|gif|svg)$/i,
use: [
{
loader: 'file-loader',
loader: "file-loader",
},
],
},
],
},
resolve: {
extensions: ['.js', '.vue'],
extensions: [".js", ".vue"],
alias: {
vue$: 'vue/dist/vue.esm.js',
vue$: "vue/dist/vue.esm.js",
},
},
plugins: [
new VueLoaderPlugin(),
new HtmlWebpackPlugin({
template: path.resolve(__dirname, '../src/index.html'),
template: path.resolve(__dirname, "../src/index.html"),
}),
],
devServer: {
contentBase: path.resolve(__dirname, './dist'),
contentBase: path.resolve(__dirname, "./dist"),
port: 8080,
hot: true,
open: true,
overlay: true,
},
}
};
2 changes: 1 addition & 1 deletion lib/_defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ export default {
brightness: 1,
saturation: 1,
y: 0,
x: 0
x: 0,
};
4 changes: 2 additions & 2 deletions lib/_directive.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ const cosha = (el, options, vnode) => {
}

if (hasBeenCreated) {
const clonedChild = [...el.parentNode.children].find(child =>
const clonedChild = [...el.parentNode.children].find((child) =>
child.classList.contains(`${className}-clone`)
);
clonedChild.style.cssText = createCloneStyles(clonedChild.style, options);
}
};

export default options => {
export default (options) => {
const mergedOptions = Object.assign(defaults, options);

const inserted = (el, { value }, vnode) => {
Expand Down
2 changes: 1 addition & 1 deletion lib/_styles.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const createWrapperClass = className => {
const createWrapperClass = (className) => {
const created = document.getElementById(`${className}-class`);

if (created) {
Expand Down
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import cosha from "./_directive";
const plugin = {
install(Vue, options) {
Vue.directive("cosha", cosha(options));
}
},
};

export default plugin;
Loading

0 comments on commit 64d6f95

Please sign in to comment.