widget-remove

Retract a Foundation widget's WidgetType and remove its Svelte component and dispatch branches.

19|3|Updated Jul 19, 2024
One-click install
npx skills add https://github.com/danielterra/FOUNDATION --skill widget-remove
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: widget-remove
Source: https://github.com/danielterra/FOUNDATION/tree/main/.claude/skills/widget-remove
Command: npx skills add https://github.com/danielterra/FOUNDATION --skill widget-remove

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Widget retirement provides a safe, auditable way to remove deprecated Foundation widgets from both the ontology and the UI, preventing broken references and stale code.

Core Features & Use Cases

  • Retract the WidgetType from the ontology and delete the corresponding Svelte component file to prevent orphaned code.
  • Update WidgetManager to remove the widget's import and its conditional dispatch branch, ensuring a clean build.
  • Use Case: decommission a widget type that is no longer used but keep the system integrity intact.

Quick Start

Retire the target WidgetType by retracting it, delete its component file, and update WidgetManager accordingly.

Frequently Asked Questions about widget-remove

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I safely remove a Foundation widget from my Svelte codebase?

To remove a Foundation widget, retract its WidgetType from the ontology, delete the corresponding Svelte component file, and update WidgetManager to strip imports and dispatch branches, ensuring a clean build with no regressions.

What happens to the ontology when decommissioning a widget type?

Decommissioning a widget type requires retracting its specific WidgetType entry from the ontology, which prevents broken references and safely retires the deprecated widget from the system foundation.

Do I need to update the WidgetManager when deleting a Svelte component?

Yes, updating the WidgetManager is required when deleting a Svelte component. You must remove the widget's import statement and its conditional dispatch branch to prevent orphaned code and ensure build integrity.

What is the best way to prevent broken references when retiring unused widgets?

The best way to prevent broken references is a full widget retirement workflow: retracting the WidgetType, deleting the Svelte component, updating WidgetManager dispatch branches, and running a local build check.

Why does my local build fail after removing a widget component file?

A local build fails after removing a widget component file if the WidgetManager still contains the widget's import or conditional dispatch branch, requiring you to clean up manager logic to restore build integrity.