RuleStack

Configs

Stacks

Compare

Diff

RuleStack

Configs

Stacks

Compare

Diff

Read API

RuleStack

Configs

Stacks

Compare

Diff

Read API

Configs/Cursor rules/Tuya-Community/miniapp-smart-ui

Cursor rule

.cursor/rules/wxs-es5.mdc

WXS 仅允许 ES5,用于模板内性能敏感计算

Cursor rules

Quality

39/100

Scores the file, not the repository.

Length

76 words

4 headings · 1 code blocks

Repository

2

— · pushed 2 days ago

Last changed

3 days ago

First indexed 3 days ago.
Tuya-Community/miniapp-smart-ui/.cursor/rules/wxs-es5.mdcRawGitHub
1---
2description: WXS 仅允许 ES5,用于模板内性能敏感计算
3globs: packages/**/*.wxs
4alwaysApply: false
5---
6 
7# WXS 规范
8 
9## 语法限制
10 
11- **仅写 ES5 语法**:使用 `function`、`var`,禁止 `const`/`let`、箭头函数、模板字符串、解构、class 等。
12- 适用于在模板侧做的计算,减轻 index.ts 与 setData 压力;简单逻辑仍可放在 ts。
13 
14## 正确写法示例
15 
16```javascript
17// ✅ 使用 function、var、字符串拼接
18function getHeight(contentHeight) {
19 var height = contentHeight
20 ? typeof contentHeight === 'number'
21 ? contentHeight + 'rpx'
22 : contentHeight
23 : 'undefined';
24 return 'height: ' + height + ';';
25}
26```
27 
28## 避免
29 
30- ❌ `const` / `let`
31- ❌ `() => {}`
32- ❌ `` `height: ${h}` ``
33- ❌ 解构、展开、class、import/require
34 

Sections

  • WXS 规范
  • 语法限制
  • 正确写法示例
  • 避免

Stack — with the evidence

typescript

(1.00)

jest

(1.00)

vue

(0.70)

javascript

(0.60)

eslint

(0.60)

github-actions

(0.60)

Glob targeting

  • packages/**/*.wxs

Format

Cursor rules

The most expressive format here. Many small .mdc files, each with frontmatter declaring when it should load, so a rule about migrations only enters context when a migration is open. Costs the most to maintain and only one editor reads it.

What the corpus says about it

Repository

Owner
Tuya-Community
Language
—
License
—
Archived
no

All configs in this repo

Also in Tuya-Community/miniapp-smart-ui

Diff this repo’s formats

One repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?

The other instruction files in this repository
RepositoryFormatStackCoversScoreChanged
Tuya-Community/miniapp-smart-ui.cursor/rules/component-structure.mdc · 2Cursor rulestypescriptjest+4no sections38/1003 days ago
Tuya-Community/miniapp-smart-ui.cursor/rules/demo-and-i18n.mdc · 2Cursor rulestypescriptjest+4testdocs50/1003 days ago
Tuya-Community/miniapp-smart-ui.cursor/rules/miniapp-test.mdc · 2Cursor rulestypescriptjest+4test63/1003 days ago
Tuya-Community/miniapp-smart-uiAGENTS.md · 2AGENTS.mdtypescriptjest+4setuptest34/1003 days ago
Diff against .cursor/rules/component-structure.mdc Diff against .cursor/rules/demo-and-i18n.mdc Diff against .cursor/rules/miniapp-test.mdc Diff against AGENTS.md

Similar configs

Same format, overlapping stack, ranked by quality.

Same format, overlapping stack, ranked by quality
RepositoryFormatStackCoversScoreChanged
hiromaily/go-crypto-wallet.cursor/rules/typescript.mdc · 126Cursor rulesgobun+5setupbuildtestlint-format+6100/1003 days ago
TechSquidTV/Hermes.cursor/rules/10-hermes-api.mdc · 45Cursor rulestypescriptpytest+15testlint-formatstylearch+5100/1003 days ago
markstev/mark-starter.cursor/rules/frontend.mdc · 0Cursor rulestypescriptturborepo+14setuptestlint-formatstyle+699/1003 days ago
Allymahmoud/case-intake-platform.cursor/rules/frontend.mdc · 0Cursor rulestypescriptturborepo+13setuptestlint-formatstyle+799/1003 days ago
dodgecfr/combatfilms-webapp.cursor/rules/frontend.mdc · 0Cursor rulestypescriptturborepo+15setuptestlint-formatstyle+799/1003 days ago
deifos/clipmira-subtitles.cursor/rules/frontend.mdc · 1Cursor rulestypescriptnextjs+5setuptestlint-formatstyle+799/1003 days ago
langflow-ai/langflow.cursor/rules/docs_development.mdc · 153kCursor rulespythonnode+16setupbuildtestlint-format+797/1003 days ago
TechSquidTV/Hermes.cursor/rules/20-hermes-api-tests.mdc · 45Cursor rulestypescriptpytest+15teststyletesting-strategysecurity+397/1003 days ago
RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack