@aziontech/webkit

中文文档
5.9.0发布于 2026/11/05MITES Module构建来源已验证近 30 天下载 4237

Reusable UI components and design system utilities for building Azion web interfaces.

原始使用文档
文档目录11 节
  1. Getting started
  2. Quick start with AI
  3. 1 · Install
  4. 2 · Add the theme CSS
  5. 3 · Add your first component
  6. 4 · Try it in the playground
  7. 5 · Stay on-pattern (the lint does the remembering)
  8. 6 · Explore from the terminal
  9. Packages
  10. Requirements
  11. License

@aziontech/webkit

Azion's design system for Vue 3 — 100+ accessible, token-driven components, plus the tooling that keeps every project using them on-pattern: an ESLint plugin (every rule error), a Stylelint config, an MCP server that guides AI coding tools, and a CLI that wires it all in one command.

  • Playground: every component ships interactive stories in the Storybook, with controls for every prop.
  • Styleguide: docs/STYLEGUIDE.md — every code standard in full, with the gate that blocks each one.
  • Guidelines: docs/GUIDELINES.md — the one-page digest (build & use on-pattern).

Getting started

Quick start with AI

Using Claude Code, Cursor, or another AI coding tool? Paste this into your agent:

Install @aziontech/webkit, @aziontech/theme, and @aziontech/icons in this project, then run npx @aziontech/webkit init to wire the lint, the MCP server, and the agent docs.

The MCP server it wires gives your AI the full component catalog (list_components, get_component, list_tokens, suggest_component, get_best_practices, validate_usage) — so it writes the right import, prop, and token on the first try.

1 · Install

npm install @aziontech/webkit @aziontech/theme @aziontech/icons

Then wire the project (lint presets, MCP, pre-commit, agent docs) in one command:

npx @aziontech/webkit init

init reads your project first and never clobbers existing files — run with --dry-run to preview the plan. See docs/toolkit/cli.md.

2 · Add the theme CSS

In your app entry (e.g. src/main.js):

import '@aziontech/theme/globals.css' // design tokens (light/dark aware)
import '@aziontech/icons' // the icon font

Using Tailwind? The theme also ships a preset — @aziontech/theme/tailwind-preset — so the semantic utilities (text-body-sm, bg-[var(--primary)], …) resolve in your build.

3 · Add your first component

Every component is a flat, tree-shakeable import — @aziontech/webkit/<name>:

<script setup>
import Button from '@aziontech/webkit/button'
import FieldText from '@aziontech/webkit/field-text'
</script>

<template>
  <FieldText name="email" label="Email" />
  <Button kind="primary" @click="submit">Create account</Button>
</template>

Composition components expose a compound API (Table.Row, Table.Cell) and a tree-shakeable root (@aziontech/webkit/table-root) when you only need the root.

4 · Try it in the playground

The Storybook is the live playground: every component ships its stories — the Default story is interactive, with controls for every prop — plus copy-paste-ready "Show code" snippets that run as-is when pasted into your app.

# in this repo
pnpm storybook:dev

The published Storybook is at https://webkit.azion.app/. Local setup for contributors (prerequisites, running and building the Storybook) is in the repository README.

5 · Stay on-pattern (the lint does the remembering)

init enables the webkit ESLint preset, where every rule is an error — wrong imports, deep/internal paths, style overrides on components, hardcoded colors, and deprecated components fail your lint instead of shipping:

// eslint.config.js
import webkit from '@aziontech/webkit/eslint-plugin'
export default [...webkit.configs.recommended]

The full pattern catalog — how to build a component by hand and how to use ours — is in docs/GUIDELINES.md.

6 · Explore from the terminal

npx @aziontech/webkit doctor   # verify the wiring is healthy (lint, MCP, theme)
npx webkit-mcp                 # the MCP server your AI tools connect to

Packages

PackageWhat it is
@aziontech/webkitThe components + eslint-plugin, stylelint-config, MCP, CLI
@aziontech/themeDesign tokens, globals.css, Tailwind preset
@aziontech/iconsThe icon font (CSS/woff2) + catalog

Requirements

  • Vue 3.5+ (components use defineModel and useId)
  • VeeValidate 4.x (form fields only)

License

MIT

版本与发布记录

@aziontech/webkit 共发布 107 个版本,首次发布于 2026/03/12;过去 12 个月发布了 107 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
5.9.0latest2026/11/053 天前
5.8.02026/11/044 天前
5.7.02026/10/2711 天前
5.6.02026/10/2415 天前
5.5.02026/10/2018 天前
5.4.02026/10/071 个月前

其他发布通道:legacy-v3 → 3.9.4。

关于 @aziontech/webkit 的常见问题

@aziontech/webkit 是什么?

Reusable UI components and design system utilities for building Azion web interfaces.

如何安装 @aziontech/webkit?

在项目目录运行 npm install @aziontech/webkit,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:vue(^3.5.29)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。它还提供命令行工具 webkit、webkit-mcp,可以用 npx webkit 直接运行。

@aziontech/webkit 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/aziontech__webkit 是否存在。

@aziontech/webkit 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@aziontech/webkit 可以商用吗?

@aziontech/webkit 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@aziontech/webkit 的下载量有多少?

根据 npm 官方下载统计,@aziontech/webkit 在 2026/10/08 – 2026/11/06 这 30 天内被下载 4,237 次,日均约 141 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@aziontech/webkit 还在维护吗?

最新版本 5.9.0 发布于 2026/11/05(3 天前);至今共发布 107 个版本,其中过去 12 个月发布了 107 个;首次发布于 2026/03/12。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。