@af-mobile/eslint-plugin 2.2.0 → 2.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -1,6 +1,8 @@
1
1
  // af-mobile UI —— eslint-plugin-af-mobile 入口(ESLint 9 flat config 兼容)
2
2
  // 24 条规则:L1(2) + L2(8) + L3(6) + L3.5(5) + k(3)
3
3
  // (definePage 消费端 7 条规则已随 definePage 全局单例移除)
4
+ import { createRequire } from 'node:module';
5
+ const require = createRequire(import.meta.url);
4
6
  import noTokenModification from './rules/no-token-modification.js';
5
7
  import noInlineStyle from './rules/no-inline-style.js';
6
8
  import tokenWhitelist from './rules/token-whitelist.js';
@@ -27,7 +29,7 @@ import kNoObjectInterpolation from './rules/k-no-object-interpolation.js';
27
29
  import kForRequireKey from './rules/k-for-require-key.js';
28
30
 
29
31
  const plugin = {
30
- meta: { name: 'eslint-plugin-af-mobile', version: '2.1.0' },
32
+ meta: { name: 'eslint-plugin-af-mobile', version: require('./package.json').version },
31
33
  rules: {
32
34
  // L1(2 条,全部 error;tokens-css-locked 由 CODEOWNERS + 分支保护,非 ESLint 规则)
33
35
  'no-token-modification': noTokenModification,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@af-mobile/eslint-plugin",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "af-mobile UI ESLint plugin — 24 rules (L1/L2/L3/L3.5/k) enforcing design-system + Web Component + k-layer constraints",
5
5
  "type": "module",
6
6
  "main": "./index.js",
@@ -1,9 +1,10 @@
1
1
  {
2
2
  "version": "v1",
3
- "af-mobileVersion": "1.7.0",
3
+ "af-mobileVersion": "1.9.0",
4
4
  "classes": {
5
5
  "recipe": [
6
6
  "actions",
7
+ "app-shell",
7
8
  "avatar",
8
9
  "badge",
9
10
  "body",