Token导航 LogoToken导航

Agent Skill · 前端设计

ionic-vue(ionic Vue 前端)

用于辅助前端页面、组件、样式和交互逻辑的开发与维护。它适合让 Agent 生成或审查 React、Next.js、Vue、Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

ionic-vue 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为操作浏览器;许可证信息还不明确,第三方扫描已通过,按安装量在前端设计类的 10,216 个 Skill 里排第 3,458。

总安装 1,317周安装 56GitHub Stars 19下载 461核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:ionic-vue(ionic Vue 前端)
来源仓库:https://github.com/capawesome-team/skills
仓库路径:skills/ionic-vue
安装命令:
npx skills add https://github.com/capawesome-team/skills --skill ionic-vue
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/capawesome-team/skills --skill ionic-vue

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

ionic-vue 用于辅助前端页面和组件的开发,适合生成或审查 Vue 相关代码。适用于组件结构整理、样式开发和布局问题排查等前端任务。通过 npx skills add 命令从指定 GitHub 仓库安装,需结合项目设计系统使用。涉及页面改动时应配合本地预览确认视觉效果和兼容性。

避免生成孤立代码片段,需考虑路由和构建方式的整体适配。

来源仓库内路径:skills/ionic-vue

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/capawesome-team/skills --skill ionic-vue;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要操作浏览器,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

ionic-vue 怎么安装?

在终端执行 npx skills add https://github.com/capawesome-team/skills --skill ionic-vue。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

ionic-vue 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

ionic-vue 需要什么权限?

权限级别是操作浏览器。该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

ionic-vue 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

ionic-vue 用的人多吗?

公开数据是累计安装 1,317 次,近一周安装 56 次,下载 461 次,GitHub 19 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

ionic-vue 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理前端设计类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

前端设计类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
frontend-design

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
ionic-vue

ionic Vue 前端 · 本页

1,31719操作浏览器未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Ionic Vue

Develop Ionic apps with Vue — project structure, components, navigation, lifecycle hooks, composables, and Vue-specific patterns.

Prerequisites

  1. Ionic Framework 7 or 8 with @ionic/vue.
  2. Vue 3.
  3. Node.js and npm installed.
  4. For iOS: Xcode installed.
  5. For Android: Android Studio installed.

Agent Behavior

  • Auto-detect before asking. Check the project for package.json dependencies (@ionic/vue, vue, @capacitor/core), platforms (android/, ios/), build tools (vite.config.ts), and TypeScript usage. Only ask the user when something cannot be detected.
  • Guide step-by-step. Walk the user through the process one step at a time. Never present multiple unrelated questions at once.
  • Adapt to the project. Detect whether the project uses <script setup> (Composition API) or Options API and generate code that matches the existing style. Default to <script setup lang="ts"> for new files unless the project uses a different pattern.

Procedures

Step 1: Analyze the Project

Auto-detect the following by reading project files:

  1. Ionic version: Read @ionic/vue version from package.json.
  2. Vue version: Read vue version from package.json.
  3. Capacitor version: Read @capacitor/core version from package.json (if present).
  4. TypeScript: Check if tsconfig.json exists and if .vue files use <script setup lang="ts">.
  5. Platforms: Check which directories exist (android/, ios/).
  6. Router config: Locate the router file (typically src/router/index.ts).
  7. Project template: Determine if the project uses tabs, side-menu, or blank template by examining the router configuration and App.vue.

Step 2: Project Structure

A standard Ionic Vue project follows this structure:

project-root/
├── android/                  # Android native project (generated by Capacitor)
├── ios/                      # iOS native project (generated by Capacitor)
├── public/
├── src/
│   ├── components/           # Reusable Vue components
│   ├── composables/          # Custom composables
│   ├── router/
│   │   └── index.ts          # Vue Router configuration (uses @ionic/vue-router)
│   ├── theme/
│   │   └── variables.css     # Ionic CSS custom properties
│   ├── views/                # Page components (routed views)
│   ├── App.vue               # Root component (contains IonApp + IonRouterOutlet)
│   └── main.ts               # Entry point (installs IonicVue plugin)
├── capacitor.config.ts       # Capacitor configuration
├── package.json
├── tsconfig.json
└── vite.config.ts

If the project does not follow this structure, adapt all guidance to the project's actual directory layout. Do not restructure the project unless the user explicitly asks.

Step 3: App Entry Point and Root Component

The entry point src/main.ts installs the IonicVue plugin and mounts the app:

import { createApp } from 'vue';
import { IonicVue } from '@ionic/vue';
import App from './App.vue';
import router from './router';

/* Ionic CSS */
import '@ionic/vue/css/core.css';
import '@ionic/vue/css/normalize.css';
import '@ionic/vue/css/structure.css';
import '@ionic/vue/css/typography.css';
import '@ionic/vue/css/padding.css';
import '@ionic/vue/css/float-elements.css';
import '@ionic/vue/css/text-alignment.css';
import '@ionic/vue/css/text-transformation.css';
import '@ionic/vue/css/flex-utils.css';
import '@ionic/vue/css/display.css';

/* Theme */
import './theme/variables.css';

const app = createApp(App).use(IonicVue).use(router);

router.isReady().then(() => {
  app.mount('#app');
});

The root App.vue contains IonApp and IonRouterOutlet:

<template>
  <ion-app>
    <ion-router-outlet />
  </ion-app>
</template>

<script setup lang="ts">
import { IonApp, IonRouterOutlet } from '@ionic/vue';
</script>

Step 4: Components and IonPage

Read references/components.md for detailed component patterns.

Key rules:

  1. Import all Ionic components from @ionic/vue — e.g., import {IonButton, IonContent, IonPage} from '@ionic/vue'.
  2. Every routed page must use IonPage as its root template element. Without it, page transitions break and Ionic lifecycle hooks do not fire.
  3. Access Web Component methods via $el — e.g., contentRef.value.$el.scrollToBottom(300).
  4. Import icons as SVG references from ionicons/icons — never pass icon names as strings.
  5. Use v-model on Ionic form components (IonInput, IonToggle, IonSelect, IonCheckbox, IonRange).
  6. Use kebab-case for Ionic event names in templates — e.g., @ion-change, @ion-infinite.

Step 5: Navigation and Routing

Read references/navigation.md for detailed routing patterns.

Key principles:

  1. Import createRouter from @ionic/vue-router, not from vue-router. The Ionic version wraps Vue Router to enable page transitions.
  2. Declarative navigation: Use router-link attribute on Ionic components with optional router-direction and router-animation.
  3. Programmatic navigation: Use the useIonRouter composable for Ionic-specific transitions, or useRouter from vue-router for standard navigation.
  4. Lazy load routes with component: () => import('@/views/DetailPage.vue').
  5. Tab routing: Use nested routes with IonTabs and IonRouterOutlet. Each tab maintains its own navigation stack.
  6. Never cross-route between tabs — only tab bar buttons should switch tabs. Use IonModal for views shared across tabs.

Step 6: Lifecycle Hooks

Read references/lifecycle.md for detailed lifecycle patterns.

Key principles:

  1. IonRouterOutlet keeps pages in the DOM. Vue's onMounted fires only once per page, not on every visit.
  2. Use Ionic lifecycle hooks to run logic on every page visit:

- onIonViewWillEnter — Refresh data every time the page appears. - onIonViewDidEnter — Start animations or focus inputs after the page transition finishes. - onIonViewWillLeave — Save state or unsubscribe. - onIonViewDidLeave — Clean up off-screen resources.

  1. Ionic lifecycle hooks require IonPage as the root element.
  2. Only router-mapped components receive lifecycle hooks — child components do not.

Step 7: Composables and Utilities

Read references/composables.md for detailed composable documentation.

Available composables and utilities from @ionic/vue:

FunctionPurpose
useIonRouter()Programmatic navigation with transition control
useBackButton(priority, handler)Handle Android hardware back button
useKeyboard()Reactive keyboard visibility and height
onIonViewWillEnter(cb)Lifecycle: page about to show
onIonViewDidEnter(cb)Lifecycle: page fully visible
onIonViewWillLeave(cb)Lifecycle: page about to hide
onIonViewDidLeave(cb)Lifecycle: page fully hidden
isPlatform(name)Check current platform (ios, android, hybrid, etc.)
getPlatforms()Get array of all matching platform identifiers

Step 8: Platform Detection

Use isPlatform from @ionic/vue to conditionally execute platform-specific logic:

<script setup lang="ts">
import { isPlatform } from '@ionic/vue';

const isIOS = isPlatform('ios');
const isAndroid = isPlatform('android');
const isNative = isPlatform('hybrid');
const isMobileWeb = isPlatform('mobileweb');
</script>

<template>
  <div>
    <p v-if="isNative">Running as a native app</p>
    <p v-else>Running in a browser</p>
  </div>
</template>

Supported identifiers: android, capacitor, cordova, desktop, electron, hybrid, ios, ipad, iphone, mobile, mobileweb, phablet, pwa, tablet.

Step 9: Build and Run

After implementing changes:

npm run build
npx cap sync
npx cap run android
npx cap run ios

For development with live reload:

ionic serve

For native live reload:

ionic cap run android --livereload --external
ionic cap run ios --livereload --external

Error Handling

  • **Failed to resolve component: ion-***: The Ionic component is not imported. Add the missing import from @ionic/vue in the <script> section (e.g., import {IonButton} from '@ionic/vue').
  • Page transitions not working: Verify that the page component uses IonPage as its root template element. Without IonPage, transitions and lifecycle hooks silently fail.
  • Ionic lifecycle hooks not firing: Ensure IonPage is the root element and the component is directly mapped to a route in the router configuration. Lifecycle hooks do not fire on child components.
  • Method on component is not a function: Access the underlying Web Component via $el — e.g., ref.value.$el.scrollToBottom(), not ref.value.scrollToBottom().
  • Slot attribute deprecation warning: Ionic uses Web Component slots, which linters misidentify as deprecated Vue 2 slots. Disable the ESLint rule: 'vue/no-deprecated-slot-attribute': 'off'.
  • Event listeners not firing: Use kebab-case event names in templates (ion-modal-did-present) and in addEventListener calls. Do not use camelCase.
  • useIonRouter or useBackButton fails: These composables use Vue's inject() internally and must be called inside setup() or <script setup>, not in standalone functions or callbacks.
  • Tab navigation loses state: Each tab maintains its own stack. Do not use router.go() with non-linear (tab-based) routing. Use useIonRouter().push() or router-link instead.
  • Vue onMounted fires only once: IonRouterOutlet caches pages in the DOM. Use onIonViewWillEnter instead of onMounted for logic that must run every time the page is shown.
  • Content overlaps tab bar or header: The page component is missing IonPage as the root element. IonPage sets up the proper flexbox layout.

Related Skills

  • ionic-app-development — General Ionic development guidance: components, theming, CLI usage.
  • ionic-app-creation — Create a new Ionic app from scratch.
  • capacitor-vue — Capacitor-specific Vue patterns (plugins, hooks, services) without Ionic Framework.
  • ionic-app-upgrades — Upgrade Ionic Framework to a newer version.

平台分布

Codex

38.36%
按下载量换算177

Claude

29.52%
按下载量换算136

Cursor

20.18%
按下载量换算93

Gemini CLI

9.5%
按下载量换算44

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills