@elmethis/vue

Vue 3 component library for elmethis.
7,483 3
Install
npm install @elmethis/vue
Latest Version:0.23.0
Vue:3
Last Updated:Oct 21, 2026
Links: GitHub  ·  npm
Maintainer: 46ki75

@elmethis/vue

Vue 3 component library for elmethis.

Components and hooks follow the shared Elmethis component surface:

  • design tokens come from @elmethis/core (import "@elmethis/core/tokens.css");
  • theming is native via CSS light-dark() + color-scheme;
  • files are kebab-case, styles use CSS Modules with the .elm-* class convention, and specs are co-located.

Authoring style

Components are authored in TSX, not single-file .vue components, to keep the surface aligned with the React and Solid siblings. Each component is a defineComponent whose setup returns a render function:

import { defineComponent } from "vue";
import styles from "./elm-divider.module.css";

export const ElmDivider = defineComponent({
  name: "ElmDivider",
  inheritAttrs: false,
  setup(_, { attrs }) {
    return () => <hr class={styles["elm-divider"]} {...attrs} />;
  },
});

TSX is compiled by @vitejs/plugin-vue-jsx; types/.d.ts are emitted with vue-tsc. Note Vue JSX is its own dialect (class not className, slots as child functions, v-model is manual modelValue + onUpdate:modelValue).

Scripts

Script Purpose
pnpm dev Storybook dev server (port 19231)
pnpm build Build the library (vite build) + types (vue-tsc)
pnpm test.unit Unit specs (happy-dom + Vue Test Utils, SSR)
pnpm test.browser Browser specs (real Chromium via Playwright)
pnpm lint Oxlint
pnpm lint.css Stylelint
pnpm fmt Oxfmt

Testing layers

  • *.spec.ts(x) → unit (pnpm test.unit): pure logic, CSR via Vue Test Utils, and SSR via renderToString from vue/server-renderer.
  • *.browser.spec.tsx → browser (pnpm test.browser): real Chromium, only for behavior the unit DOM can't fake (native <dialog>/focus/layout, real Web APIs, color-scheme).

Version History

Version Released Vue License
0.23.0 ^3.4.0
0.22.1 ^3.4.0
0.22.0 ^3.4.0
0.21.0 ^3.4.0
0.20.0 ^3.4.0