All skills
skilld-dev avatar

/vuetify-skilld

@b9c39cb

Vue Material Component Framework. Use when writing, debugging, or configuring code that imports vuetify v4.x. Covers createVuetify setup, components and labs, composables, theming, icons, dates and locale, styles and SASS variables, treeshaking, and v3 to v4 migration.

Use this Skill: https://skilld.dev/gh/skilld-dev/vue-ecosystem-skills/vuetify-skilld

This session only. Nothing lands on disk.

referencescomposables.md

≈839 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Public composables

All are named exports of the vuetify entry point (lib/composables/index.js:1). Each must be called inside a component setup context.

useTheme

const theme = useTheme()
theme.name.value        // active theme name
theme.current.value.colors.primary
theme.change('dark')    // switch to a named theme
theme.toggle()          // light <-> dark
theme.cycle(['light', 'dark', 'custom'])
theme.global.name.value // global (non-scoped) theme name

Instance surface: change, cycle, toggle, isDisabled, isSystem, themes, name, current, computedThemes, styles, global (lib/composables/theme.d.ts:45).

useDisplay

const { mobile, name, width, height, platform, xs, smAndUp, mdAndDown } = useDisplay()
// name.value: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'
// mobile is driven by display.mobileBreakpoint (number or breakpoint name)

All flags are refs (xs...xxl, smAndUp...xlAndDown, smAndDown...xlAndDown), plus width, height, mobile, mobileBreakpoint, platform (lib/composables/display.d.ts:44). Thresholds and mobileBreakpoint are configurable, see configuration.md.

useDate

const date = useDate()
date.format('2010-04-13', 'fullDateWithWeekday') // "Tuesday, April 13, 2010"
date.parseISO('2024-01-01T00:00:00Z')            // adapter date
date.toISO(date.date())                          // ISO string
date.isSameDay(a, b); date.addDays(d, 3)

Built-in format keys include fullDate, normalDateWithWeekday, keyboardDate, fullTime24h, monthAndYear (https://vuetifyjs.com/features/dates/). Pickers and VDateInput exchange native Date objects; use parseISO/toISO at the boundary. Adapter surface in lib/composables/date/date.d.ts:23.

useLocale / useRtl

const { current, t, n, format } = useLocale()  // t translates component messages
const { isRtl } = useRtl()

Locale messages come from vuetify/locale plus any locale.messages config.

useGoTo

const goTo = useGoTo()
await goTo(0)                 // scroll to top
await goTo('#target', { duration: 300, easing: 'easeInOutCubic' })

useDefaults

const defaults = useDefaults(['VBtn'])  // resolved defaults for a component, incl. global config

Read (not set) the merged defaults that apply to a component in the current VDefaultsProvider scope.

useLayout

Returns registered layout items and rects; used with VLayout, VAppBar, VNavigationDrawer, VMain (lib/composables/layout.js).

useHotkey

useHotkey('cmd+s', (e) => save(e))       // cmd = Command on Mac, Control elsewhere
useHotkey('ctrl+shift+k', openPanel, {
  event: 'keydown',       // default keydown
  inputs: true,           // ignore keystrokes in inputs when false
  preventDefault: true,
  sequenceTimeout: 1000,  // for multi-key sequences like 'g d'
})

Signature: useHotkey(keys: MaybeRef<string | undefined>, callback, options?) => () => void; the return value unregisters the hotkey (lib/composables/hotkey/hotkey.d.ts:6). Key aliases include cmd -> mod (lib/composables/hotkey/key-aliases.js:10). Prefer cmd over hardcoding ctrl for cross-platform apps.

useMask

Input mask support used by VMaskInput (labs) (lib/composables/mask/). Returns mask parsing helpers for controlled inputs.

Source: SKILL.md on GitHub

No alerts9d3 checks · Risk SAFE
  • Gen Agent Trust Hub9d

    The skill is a comprehensive technical reference for Vuetify 4.x, providing setup instructions, component maps, and migration guides. It adheres to best practices and references only official or well-known development resources.

  • Socket9d

    No alerts

  • Snyk9d

    Risk: LOW · No issues

Signed by skilld at b9c39cb. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last week.

Activeupdated last week

README badge

README badge for skilld-dev/vue-ecosystem-skills/vuetify-skilld