<script>
import Moveable from "vue-moveable";

export default {
    components: { Moveable },
    data() {
        return {};
    },
    methods: {
        onScaleStart(e) {
            e.setMinScaleSize([100, 100]);
            e.setMaxScaleSize([500, 500]);
        },
        onRender(e) {
            e.target.style.cssText += e.cssText;
        }
    }
};
</script>
<template>
    <div class="container">
        <div class="target">Target</div>
        <Moveable
            :target="'.target'"
            :draggable="true"
            :scalable="true"
            @scaleStart="onScaleStart"
            @render="onRender"/>
    </div>
</template>