@fewangsit/wangsvue 1.5.229-alpha.33 → 1.5.229-alpha.34
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/mcp/components.json +1 -1
- package/mcp/components.summary.txt +1 -1
- package/mcp/main.js +41 -30
- package/mcp/package.json +5 -5
- package/package.json +1 -1
package/mcp/components.json
CHANGED
package/mcp/main.js
CHANGED
|
@@ -22,7 +22,7 @@ const cl = "https://fewangsit.gitbook.io", ul = "https://fewangsit.gitbook.io/vu
|
|
|
22
22
|
output_dir: ".trae/rules"
|
|
23
23
|
},
|
|
24
24
|
copilot: {
|
|
25
|
-
applyTo: "**",
|
|
25
|
+
applyTo: "'**'",
|
|
26
26
|
output_dir: ".github/instructions"
|
|
27
27
|
},
|
|
28
28
|
default: {
|
|
@@ -47,17 +47,23 @@ function Qi(t) {
|
|
|
47
47
|
});
|
|
48
48
|
});
|
|
49
49
|
}
|
|
50
|
-
function ll(t) {
|
|
51
|
-
const
|
|
52
|
-
`),
|
|
53
|
-
for (const
|
|
54
|
-
const
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
50
|
+
function ll(t, e = !1) {
|
|
51
|
+
const n = t.split(`
|
|
52
|
+
`), r = [];
|
|
53
|
+
for (const s of n) {
|
|
54
|
+
const i = s.match(/\[([^\]]+)\]\(([^)]*\/(?:style-guide|testing-guide)\/[^)]+)\)/);
|
|
55
|
+
if (i) {
|
|
56
|
+
const a = i[1], o = i[2];
|
|
57
|
+
e ? (a.toLowerCase().includes("api-services") || o.toLowerCase().includes("api-services")) && r.push({
|
|
58
|
+
title: a,
|
|
59
|
+
path: o
|
|
60
|
+
}) : r.push({
|
|
61
|
+
title: a,
|
|
62
|
+
path: o
|
|
63
|
+
});
|
|
64
|
+
}
|
|
59
65
|
}
|
|
60
|
-
return
|
|
66
|
+
return r;
|
|
61
67
|
}
|
|
62
68
|
function Ds(t) {
|
|
63
69
|
const n = t.replace(/^\/vue\/docs\//, "").split("/");
|
|
@@ -89,26 +95,26 @@ function fl(t, e, n) {
|
|
|
89
95
|
return l.endsWith(".md") || (l += ".md"), `[${o}](${l})`;
|
|
90
96
|
}), s + i;
|
|
91
97
|
}
|
|
92
|
-
async function pl(t) {
|
|
98
|
+
async function pl(t, e = !1) {
|
|
93
99
|
try {
|
|
94
|
-
const
|
|
100
|
+
const n = yc(t), r = `${process.cwd()}/${n.output_dir}`;
|
|
95
101
|
console.log("Fetching documentation index...");
|
|
96
|
-
const
|
|
97
|
-
console.log(`Found ${
|
|
98
|
-
for (const
|
|
102
|
+
const s = await Qi(ul), i = ll(s, e);
|
|
103
|
+
console.log(`Found ${i.length} documentation pages to fetch`), console.log(`Output directory: ${n.output_dir}`), e && console.log("Filter: API services documentation only");
|
|
104
|
+
for (const a of i)
|
|
99
105
|
try {
|
|
100
|
-
console.log(`Fetching: ${
|
|
101
|
-
const
|
|
102
|
-
dl(
|
|
103
|
-
const
|
|
104
|
-
xr.writeFileSync(
|
|
105
|
-
} catch (
|
|
106
|
-
console.error(`✗ Failed to fetch ${
|
|
106
|
+
console.log(`Fetching: ${a.title} from ${a.path}`);
|
|
107
|
+
const o = `${cl}${a.path}`, c = await Qi(o), l = Ds(a.path), d = `${r}/${l}`;
|
|
108
|
+
dl(d);
|
|
109
|
+
const h = fl(c, a.title, t);
|
|
110
|
+
xr.writeFileSync(d, h, "utf8"), console.log(`✓ Saved: ${n.output_dir}/${l}`);
|
|
111
|
+
} catch (o) {
|
|
112
|
+
console.error(`✗ Failed to fetch ${a.title}:`, o instanceof Error ? o.message : String(o));
|
|
107
113
|
}
|
|
108
114
|
console.log(`
|
|
109
115
|
Documentation fetch completed!`);
|
|
110
|
-
} catch (
|
|
111
|
-
throw console.error("Error:",
|
|
116
|
+
} catch (n) {
|
|
117
|
+
throw console.error("Error:", n instanceof Error ? n.message : String(n)), n;
|
|
112
118
|
}
|
|
113
119
|
}
|
|
114
120
|
function vc(t) {
|
|
@@ -17572,11 +17578,14 @@ Usage: wangsvue-mcp <command> [arguments]
|
|
|
17572
17578
|
|
|
17573
17579
|
Commands:
|
|
17574
17580
|
run Start the MCP server with STDIO transport
|
|
17575
|
-
init-rules <editor> Fetch documentation and initialize rules for agentic editors
|
|
17581
|
+
init-rules <editor> [options] Fetch documentation and initialize rules for agentic editors
|
|
17576
17582
|
|
|
17577
17583
|
Arguments for init-rules:
|
|
17578
17584
|
editor Set agentic editor for metadata configuration (required)
|
|
17579
17585
|
|
|
17586
|
+
Options:
|
|
17587
|
+
--api-services Only initialize rules for API services documentation
|
|
17588
|
+
|
|
17580
17589
|
Available editors:
|
|
17581
17590
|
kiro - Kiro editor (inclusion: always, output: .kiro/steering/)
|
|
17582
17591
|
windsurf - Windsurf editor (trigger: always-on, output: .windsurf/rules/)
|
|
@@ -17591,6 +17600,7 @@ Examples:
|
|
|
17591
17600
|
wangsvue-mcp init-rules trae
|
|
17592
17601
|
wangsvue-mcp init-rules copilot
|
|
17593
17602
|
wangsvue-mcp init-rules default
|
|
17603
|
+
wangsvue-mcp init-rules kiro --api-services
|
|
17594
17604
|
`);
|
|
17595
17605
|
}
|
|
17596
17606
|
async function y0() {
|
|
@@ -17602,7 +17612,7 @@ async function y0() {
|
|
|
17602
17612
|
await m0();
|
|
17603
17613
|
break;
|
|
17604
17614
|
case "init-rules":
|
|
17605
|
-
const n = t[1];
|
|
17615
|
+
const n = t[1], r = t.includes("--api-services");
|
|
17606
17616
|
n || (console.log(`
|
|
17607
17617
|
Usage: wangsvue-mcp init-rules <editor>
|
|
17608
17618
|
|
|
@@ -17622,11 +17632,12 @@ Examples:
|
|
|
17622
17632
|
wangsvue-mcp init-rules trae
|
|
17623
17633
|
wangsvue-mcp init-rules copilot
|
|
17624
17634
|
wangsvue-mcp init-rules default
|
|
17635
|
+
wangsvue-mcp init-rules kiro --api-services
|
|
17625
17636
|
`), process.exit(1));
|
|
17626
17637
|
try {
|
|
17627
|
-
console.log("Initializing rules..."), await pl(n), console.log("Rules initialization completed successfully!"), process.exit(0);
|
|
17628
|
-
} catch (
|
|
17629
|
-
console.error("Failed to initialize rules:",
|
|
17638
|
+
console.log("Initializing rules..."), await pl(n, r), console.log("Rules initialization completed successfully!"), process.exit(0);
|
|
17639
|
+
} catch (s) {
|
|
17640
|
+
console.error("Failed to initialize rules:", s), process.exit(1);
|
|
17630
17641
|
}
|
|
17631
17642
|
break;
|
|
17632
17643
|
default:
|
package/mcp/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fewangsit/wangsvue-mcp",
|
|
3
|
-
"version": "1.5.229-alpha.
|
|
3
|
+
"version": "1.5.229-alpha.34",
|
|
4
4
|
"description": "MCP Server for @fewangsit/wangsvue",
|
|
5
5
|
"main": "main.js",
|
|
6
6
|
"type": "module",
|
|
@@ -10,18 +10,18 @@
|
|
|
10
10
|
"buildContext": {
|
|
11
11
|
"package": {
|
|
12
12
|
"name": "@fewangsit/wangsvue",
|
|
13
|
-
"version": "1.5.229-alpha.
|
|
13
|
+
"version": "1.5.229-alpha.34",
|
|
14
14
|
"description": "Wangsit VueJS Component Library",
|
|
15
15
|
"repository": "https://github.com/fewangsit/wangsvue",
|
|
16
16
|
"workspace": "wangsvue"
|
|
17
17
|
},
|
|
18
18
|
"build": {
|
|
19
|
-
"timestamp": "2026-01-
|
|
19
|
+
"timestamp": "2026-01-23T08:18:11.448Z",
|
|
20
20
|
"gitInfo": {
|
|
21
|
-
"head": "
|
|
21
|
+
"head": "cd00ec5d7eec7b978957bea7c3a191c8e4cfb579",
|
|
22
22
|
"branch": "feat/mcp",
|
|
23
23
|
"repository": "https://github.com/fewangsit/wangsvue.git",
|
|
24
|
-
"timestamp": "2026-01-
|
|
24
|
+
"timestamp": "2026-01-23T08:18:11.259Z"
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
}
|