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

export default {
    components: { Moveable },
    setup() {
        const onScaleStart = e => {
            e.setRatio(1);
        };
        const onScale = e => {
            e.target.style.cssText += e.cssText;
        };
        return { onScaleStart, onScale };
    }
};
</script>
<template>
    <div class="container">
        <div
            class="target"
            style="transform: scale(1, 0);"
        >Target1</div>
        <Moveable
            :target="'.target'"
            :scalable="true"
            :keepRatio="true"
            @scaleStart="onScaleStart"
            @scale="onScale"/>
    </div>
</template>