@skild/core 0.13.0 → 0.13.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/dist/index.js +7 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -216,9 +216,13 @@ function parseSkillFrontmatter(skillMdContent) {
|
|
|
216
216
|
const end = trimmed.indexOf("\n---", 3);
|
|
217
217
|
if (end === -1) return null;
|
|
218
218
|
const yamlBlock = trimmed.slice(3, end).trim();
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
219
|
+
try {
|
|
220
|
+
const parsed = yaml.load(yamlBlock);
|
|
221
|
+
if (!parsed || typeof parsed !== "object") return null;
|
|
222
|
+
return parsed;
|
|
223
|
+
} catch {
|
|
224
|
+
return null;
|
|
225
|
+
}
|
|
222
226
|
}
|
|
223
227
|
function validateSkillDir(skillDir) {
|
|
224
228
|
const issues = [];
|