structure

structure is a cursor rule for Cursor from Kele-Bingtang/teek-design-vue3. It costs 780 tokens per session, scanned A, original, MIT.

A set of frontend project rules for organizing files, naming code, using TypeScript, and structuring Vue components. It specifies locations and conventions for components, styles, API code, utilities, types, imports, and exports.

In plain words
What is it for?
Use it when adding or reviewing Vue and TypeScript code, especially component folders, reusable logic, styles, types, and imports.
Why use it?
It gives a team a shared structure so code is easier to find, review, and maintain as the project grows.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it when adding or reviewing Vue and TypeScript code, especially component folders, reusable logic, styles, types, and imports.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/kele-bingtang/teek-design-vue3/structure
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/Kele-Bingtang/teek-design-vue3

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for structure

README.md
[![agentmods](https://agentmods.dev/badge/rules/kele-bingtang/teek-design-vue3/structure.svg)](https://agentmods.dev/rules/kele-bingtang/teek-design-vue3/structure)
Your own site
<a href="https://agentmods.dev/rules/kele-bingtang/teek-design-vue3/structure"><img src="https://agentmods.dev/badge/rules/kele-bingtang/teek-design-vue3/structure.svg" alt="Measured on agentmods" height="20"></a>
Per session 780 This file is loaded in full into every session.
When invoked 780 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00780 $0.00780
Opus 5 $0.00390 $0.00390
Sonnet 5 $0.00156 $0.00156
Haiku 4.5 $0.00078 $0.00078

Measured 3d ago against content hash 6e542c3109e6, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

structure scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/structure.mdc · 58 lines

What it actually says

您是一位注重文件存放、文件命名、代码规范的前端开发专家。

文件组织

  1. 通用组件(components)请放到 src/components/ 目录下,且按功能分子文件夹,比如 card/chart/pro/
  2. 通用可复用逻辑(composables)放在 src/composables/
  3. 通用样式放在 src/common/styles/
  4. 通用 API 请求相关文件放在 src/common/api/
  5. 通用工具函数放在 src/common/utils/
  6. Typescript 类型文件请在组件同级目录下创建 types.ts 或者 types 目录,且
  7. 上述非通用文件请在组件同级目录创建,如 src/views/lgoin 下有 index.vuecomponentscomposablesapi

命名规范

  1. 所有文件请使用 kebab-case 风格,如 pro-table.vueuse-table.tspro-table.scss
  2. 引入组件的命名为 Camel-Case,如 import ProTable from "pro-table.vue"
  3. TypeScript 接口和类型用 PascalCase,统一放在同级目录 types.tstypes/xx.ts 文件中,且组件里的 Typescript 类型移到类型文件里,如 ProTablePropsProTableEmits

TypeScript 使用

  1. 所有函数参数都要加类型注解,如果返回值可以推导则不需要添加
  2. 全局类型放在 src/types/,模块专用类型

导入与导出

  1. 使用以 @/ 为根的绝对路径导入(如 import { ProTable } from '@/components/pro/table'),如果是样式文件,则以 @styles 代替 @/common/styles 目录
  2. 每个组件目录下用 index.ts 统一导出,便于批量导入

代码结构

  1. 新组件统一使用 <script setup lang="ts"> 语法
  2. props、emits、composables 写在 script 顶部
  3. 使用 defineProps 和 defineEmits 宏定义属性和事件,用法如 defineProps<{ts 类型}>();defineEmits<{xx: []}>,这些请用 Typescript 的 interface 定义
  4. 不推荐 propsemits响应式变量computedwatchfunction生命周期 的结构写法,请使用可复用逻辑(composables)写法,即将关联性高的代码放到 function useXx 里然后暴露出来使用
  5. 使用 defineModel 代替 props.modelValue
  6. 适当换行,如变量与函数之间,scripttemplatestyle 标签之间必须换行

代码规范

  1. 使用 ESLint 和 Prettier 保证代码风格统一
  2. 遵循 eslint.config.js 中的规则

文档规范

  1. composable 和函数用 JSDoc 或 TypeScript 注释说明用途

Git 版本管理

  1. 不要提交构建产物和本地环境配置文件
  2. TODO.md 及时记录和更新待办事项
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 58 lines · 780 tokens per session scan A 6e542c3109e6

Subscribe to this mod's changes

structure is a cursor rule published in the GitHub repository Kele-Bingtang/teek-design-vue3 (277 stars, last pushed 10d ago), licensed MIT. It adds 780 tokens to every session, about $0.0039 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.