smart-connections-component-patterns
Installation
SKILL.md
Smart Connections Component Patterns
Use this skill when editing or creating Smart Connections UI components under src/components/**, especially when you need to preserve the project’s component lifecycle, listener guards, and env/settings fallbacks.
Critical
- Keep component work inside
src/components/**; do not move UI logic intosrc/main.js, release scripts, or migration files. - Match the existing component lifecycle used in this repo:
build_html(...)→render(...)→post_process(...). - Guard all event attachment with
if (!container._has_listeners)so rerenders do not duplicate handlers. - Prefer existing helpers and patterns from:
src/components/connections-list/v4.jssrc/components/connections-list-item/v3.jssrc/components/connections-view/v3.jssrc/components/connections_codeblock.jssrc/components/lookup/item_view.js
- Keep fallbacks explicit, especially
opts.connections_settings ?? env.connections_lists.settingsor the equivalent env fallback used by nearby components.