Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
[![NPM version][badge-npm-version]][url-npm] [![Node version][badge-node-version]][url-npm] [![NPM download][badge-npm-download]][url-npm] ![Dependencies][badge-dependencies] ![License][badge-license]
[![NPM version][badge-npm-version]][url-npm] [![Node version][badge-node-version]][url-npm] [![NPM download][badge-npm-download]][url-npm] ![Dependencies][badge-dependencies] ![License][badge-license]
[![NPM][image-npm]][url-npm]
适用于 Vue 3.0 的计算元素拖动状态下实时宽高的指令。
$ npm i -S v3-resize
hooks 方式
<template>
<div id="resize">
拖拽获取实时尺寸
</div>
</template>
<script setup>
import { onMounted } from 'vue'
import useResize from 'v3-resize'
onMounted(() => {
useResize(document.querySelector('#resize'), (e) => {
console.log(e)
})
})
</script>
<style lang="scss" scoped>
#resize {
border: 1px solid #ccc;
resize: both;
overflow: hidden;
}
</style>
指令方式
<template>
<div id="resize" v-resize="resize">
拖拽获取实时尺寸
</div>
</template>
<script setup>
const resize = (e) => {
console.log(e)
}
</script>
<style lang="scss" scoped>
#resize {
border: 1px solid #ccc;
resize: both;
overflow: hidden;
}
</style>
import useResize from 'v3-resize'
app.use(useResize).mount('#app')
FAQs
适用于 Vue 3.0 的计算元素实时宽高的指令。
The npm package v3-resize receives a total of 0 weekly downloads. As such, v3-resize popularity was classified as not popular.
We found that v3-resize demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.