solid-core-lifecycle
CommunityMaster SolidJS component and effect lifecycles.
Authorvallafederico
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill helps developers understand and correctly implement SolidJS lifecycle methods like onMount and onCleanup to manage component behavior, prevent memory leaks, and ensure proper resource disposal.
Core Features & Use Cases
- Component Mounting (
onMount): Execute code after a component is added to the DOM, ideal for DOM manipulation and third-party library initialization. - Resource Cleanup (
onCleanup): Register functions to run when a component unmounts or an effect is disposed, crucial for preventing memory leaks by cleaning up event listeners, subscriptions, and intervals. - Effect Lifecycle Management: Understand how cleanup functions within
createEffectwork before re-execution or disposal. - Use Case: Ensure that an event listener attached in
onMountis correctly removed inonCleanupwhen the component is no longer visible, preventing potential errors and memory leaks.
Quick Start
Explain how to use onMount to focus an input element after a SolidJS component has been rendered.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: solid-core-lifecycle Download link: https://github.com/vallafederico/solid-ai-rules/archive/main.zip#solid-core-lifecycle Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.