From shesha-developer
Analyzes a Shesha form configuration JSON and removes dead/obsolete component properties, strips console.log calls from JS code strings, validates property value types, validates the shape of dropdown values items, detects scripts referencing component labels instead of propertyNames, runs layout validations (container dimension overflow, labelCol+wrapperCol span checks, device-specific style path conflicts), validates JavaScript syntax of embedded code strings, auto-fixes API calls missing try-catch by wrapping the function body in try/catch, and auto-fixes API calls in async-context properties that are missing async/await by adding the async keyword and awaiting calls. Falls back to manual review when function structure is ambiguous. Also detects API calls using .then() chaining and flags them for conversion to async/await + try-catch. Use when a form has been migrated, components have been refactored, or you want to clean up stale properties and debug statements.
How this skill is triggered — by the user, by Claude, or both
Slash command
/shesha-developer:clean-form-configThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Identify and remove **dead properties**, **console.log debug statements**, and **type mismatches** from a Shesha form configuration.
Identify and remove dead properties, console.log debug statements, and type mismatches from a Shesha form configuration.
Read the bundled index from the skill's own assets folder:
plugins/shesha-developer/skills/clean-form-config/assets/component-properties.json
This file is maintained by the skill author and ships with the plugin — no generation step is needed. Proceed directly to Step 2.
Note for skill maintainers: To refresh the index after a shesha-reactjs upgrade, follow generate-index.md and replace the file above.
Choose one of:
Option A — Fetch from API: Follow api.md to resolve the base URL, authenticate, and retrieve the form by module + name.
Option B — Local file: Ask the user for the file path, then use Read to load it.
In both cases normalise to { components, formSettings } as described in the Normalisation section of analysis.md before continuing.
Follow analysis.md for:
console.log calls.values item shapes; run layout checks (overflow, span, device-style path); scan scripts for label used instead of propertyName.[CRITICAL].[MANUAL REVIEW] for complex scripts.async to the function signature and await before the call; fall back to [MANUAL REVIEW] for ambiguous structures. Also detects await used outside an async function (Scenario A) and auto-fixes it..then() chaining; flag as [MANUAL REVIEW] with a recommendation to convert to async/await + try-catch.Layout checks are defined in layout-checks.md — new checks can be appended there as L3, L4, etc.
After producing the cleaned JSON, ask the user:
The form has been cleaned. Would you like to push the updated config back to the Shesha backend via the API? (yes / no)
If no → skip this step, work is done.
If yes → follow Section 5 of api.md to call ImportJson.
FORM_ID and ACCESS_TOKEN are already available — use them directly.FORM_ID / ACCESS_TOKEN are not available, first follow api.md sections 1–2 to resolve the base URL and authenticate, then ask the user:
Please enter the form's
itemId(the UUID of the form configuration record):
id, type, parentId, components.IPropertySetting wrappers ({ _mode, _value, _code }) are valid for any property._mode: 'code' values are never type-checked — runtime expressions.null values are never type-checked — valid for any property type..claude/shesha/component-properties.json and re-run the skill.npx claudepluginhub shesha-io/shesha-plugins --plugin shesha-developerImplements form architecture for multi-step wizards, client/server/async validation with Zod, file uploads, and accessible design. For React/Vue/Angular/Svelte apps beyond simple forms.
Audits component library APIs for prop naming consistency, breaking changes, TypeScript coverage, default patterns, and design-to-code contract compliance.
Validates application configurations by scanning JSON, YAML, TOML, env files; creates schemas, tests for security issues, consistency, and errors across environments.