0.1.8 • Published 1 year ago

@foxyimg/vue-utils v0.1.8

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Foxy Image Logo

@foxyimg/vue-utils

npm version npm downloads

A utility functions and composables for use with Vue.

Usage

Install package:

# ✨ Auto-detect
npx nypm install @foxyimg/vue-utils

# npm
npm install @foxyimg/vue-utils

# yarn
yarn add @foxyimg/vue-utils

# pnpm
pnpm install @foxyimg/vue-utils

# bun
bun install @foxyimg/vue-utils

Usage:

import { useWritableWrappedRef, useClampedRef } from "@foxyimg/vue-utils";
const someRef = useWritableWrappedRef(25, 0, 100);  // current value: 25
someRef.value = 102;  // current value: 1

const someOtherRef = ref(12);
const clampedRef = useClampedRef(someOtherRef, 0, 15);  // clampedRef's current value: 12
someOtherRef.value = 23;  // clampedRef's current value: 15

License

Published under the MIT license.

0.1.8

1 year ago

0.1.7

1 year ago

0.1.6

1 year ago