30-scss-and-build

30-scss-and-build is a cursor rule for Cursor from sowee121/frontend-interview-vue. It costs 0 tokens per session (439 once invoked), scanned A, original, MIT.

Coding rules for Sass, a stylesheet language, and Vite, a tool that builds front-end applications. They define naming, file organization, automatic variables, and deployment paths.

In plain words
What is it for?
Use them when adding or changing global styles, layouts, or components in the Vue front end. They also guide how to reference assets and routes in development and production.
Why use it?
They prevent styles from being organized inconsistently or applied to the wrong elements, and reduce errors when the application is served from a subdirectory.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use them when adding or changing global styles, layouts, or components in the Vue front end. They also guide how to reference assets and routes in development and production.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/sowee121/frontend-interview-vue/30-scss-and-build
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/sowee121/frontend-interview-vue

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 30-scss-and-build

README.md
[![agentmods](https://agentmods.dev/badge/rules/sowee121/frontend-interview-vue/30-scss-and-build/github.svg)](https://agentmods.dev/rules/sowee121/frontend-interview-vue/30-scss-and-build)
Your own site
<a href="https://agentmods.dev/rules/sowee121/frontend-interview-vue/30-scss-and-build"><img src="https://agentmods.dev/badge/rules/sowee121/frontend-interview-vue/30-scss-and-build/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for 30-scss-and-build

Your own site · 80×15
<a href="https://agentmods.dev/rules/sowee121/frontend-interview-vue/30-scss-and-build"><img src="https://agentmods.dev/badge/rules/sowee121/frontend-interview-vue/30-scss-and-build.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 439 The whole file, excluding the scripts and references it only reads on demand.
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.00000 $0.00439
Opus 5 $0.00000 $0.00219
Sonnet 5 $0.00000 $0.00088
Haiku 4.5 $0.00000 $0.00044

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

Security

Grade A, and why

30-scss-and-build 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 10d 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/30-scss-and-build.mdc · 17 lines

What it actually says

Sass / 构建约定

  • BEM 命名:块 {domain}-{name}、元素 {block}__{part}、修饰符 {block}--{variant};统一 kebab-case。
  • 块选择器根:样式以 .site-footer.qa-block类名为块根书写;避免 footer { &.site-footer { &__line } }——会编译成 footer.site-footer__line,无法命中子元素上的 site-footer__line
  • 样式组织:全局入口 src/assets/main.scss,按序 @usetokensbaselayoutcomponents
    • _base.scss:盒模型、html/body、链接色;:where() 元素重置(margin 清零、表单 inherit、媒体 max-width)放在 #app 之后,特异性为 0,便于 BEM 覆盖。
    • _layout.scss:顶栏、章节 grid、侧栏 TOC、移动 FAB / sheet、scroll-top-fab
    • _components.scss:文章卡片、题库块、首页章节卡片、页脚。
  • 变量注入:Vite 对「非 src/assets/styles/**」的 scss/vue 自动注入 @use "variables" as *;(见 vite.config.ts)。在 src/assets/styles/**main.scss不要 重复 @use variables
  • 部署 base:生产 base/frontend-interview-vue/,开发为 /;资源与路由思维使用 import.meta.env.BASE_URL,避免硬编码根路径。
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. 10d ago First seen · 17 lines · 0 tokens per session scan A b80653241040

Subscribe to this mod's changes

30-scss-and-build is a cursor rule published in the GitHub repository sowee121/frontend-interview-vue (4 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 439 tokens. 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-08-31.