Skip to content

Commit

Permalink
Merge pull request #114 from imagekit-developer/IK-1357
Browse files Browse the repository at this point in the history
remove unused code
  • Loading branch information
imagekitio authored Apr 29, 2024
2 parents 4448120 + 860b84c commit ab086ba
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 75 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "imagekitio-vue",
"version": "3.0.0",
"version": "3.0.1",
"scripts": {
"build:lib": "./node_modules/.bin/vue-cli-service build --target lib src/index.js",
"build": "./node_modules/.bin/vue-cli-service lint --fix; npm run build:lib",
Expand Down
3 changes: 1 addition & 2 deletions src/components/IKImage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<script>
import { defineComponent } from 'vue';
import ImageKit from 'imagekit-javascript';
import { VERSION } from "../plugin";
const VERSION = "3.0.1";
export default defineComponent({
name: "ik-image",
Expand All @@ -31,7 +31,6 @@ export default defineComponent({
methods: {
getMergedOptions: function () {
return {
...this.defaultOptions,
...this.contextConfigurations
};
},
Expand Down
4 changes: 2 additions & 2 deletions src/components/IKUpload.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@

<script>
import ImageKit from "imagekit-javascript";
import { VERSION } from "../plugin";
import { inject, ref } from "vue";
const VERSION = "3.0.1";
export default {
name: "ik-upload",
props: {
urlEndpoint: { type: String, default: "", required: false },
publicKey: { type: String, default: "", required: false },
authenticator: { type: Function, required: true },
authenticator: { type: Function, required: false },
fileName: { type: String, default: "", required: false },
useUniqueFileName: { type: Boolean, default: true, required: false },
tags: { type: Array, required: false },
Expand Down
5 changes: 2 additions & 3 deletions src/components/IKVideo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<script>
import ImageKit from 'imagekit-javascript';
import { VERSION } from "../plugin";
const VERSION = "3.0.1";
export default {
name: "ik-video",
Expand All @@ -27,7 +27,6 @@ export default {
methods: {
getMergedOptions: function () {
return {
...this.defaultOptions,
...this.contextConfigurations
};
},
Expand Down Expand Up @@ -60,7 +59,7 @@ export default {
},
videoAttrs: function () {
const mergedOptions = this.getMergedOptions();
const IkClient = this.IkClient || this.getClient();
const IkClient = this.getClient();
var options = {
urlEndpoint: this.urlEndpoint ? this.urlEndpoint : mergedOptions.urlEndpoint,
Expand Down
17 changes: 0 additions & 17 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,10 @@
import * as plugin from "./plugin";
import IKImage from "./components/IKImage.vue";
import IKContext from "./components/IKContext.vue";
import IKVideo from "./components/IKVideo"
import IKUpload from "./components/IKUpload"
import { ImageKit as IKCore } from "imagekit-javascript";

const ImageKit = {
install(app, options = {}) {
if (!options.urlEndpoint || options.urlEndpoint.trim() === "") {
throw new Error("urlEndpoint is required to initialize ImageKit");
}

if (!options.components || options.components.length === 0) {
options.components = ["ik-image","ik-context","ik-video","ik-upload"];
}

plugin.install(app, options);
}
};

export {
ImageKit as default,
ImageKit,
IKImage,
IKCore,
IKContext,
Expand Down
50 changes: 0 additions & 50 deletions src/plugin.js

This file was deleted.

0 comments on commit ab086ba

Please sign in to comment.