deeleeramone/pywry/css-selectors
Claude Code and agent skill by deeleeramone/pywry
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Install
npx vskill@latest install deeleeramone/pywry/css-selectorsSKILL.md
CSS Selectors
Target elements forset_contentandset_styleupdates using CSS selectors or component IDs.
Targeting by Component ID (Preferred)
The most reliable way to target elements is by component_id:
Why component_id is Preferred
| Aspect | component_id | CSS Selector | |
|---|---|---|---|
| Reliability | Always unique | May match multiple elements | |
| Refactoring | Survives DOM changes | May break on restructure | |
| Performance | Direct lookup | May scan document | |
| Clarity | Self-documenting | Requires knowledge of DOM |
Targeting by CSS Selector
When you don't have a component_id, use CSS selectors:
Common Selector Patterns
Basic Selectors
| Selector | Matches | Example | |
|---|---|---|---|
#myid | Element with id="myid" | #header | |
.myclass | Elements with class="myclass" | .card | |
div | All div elements | span | |
* | All elements | * |
Combinators
| Selector | Matches | Example | |
|---|---|---|---|
div.myclass | Divs with class="myclass" | button.primary | |
div > p | Direct child p of div | .card > .title | |
div p | Any descendant p of div | .sidebar a | |
div + p | p immediately after div | h1 + p | |
div ~ p | All p siblings after div | h1 ~ p |
Attribute Selectors
| Selector | Matches | Example | |
|---|---|---|---|
[data-x] | Elements with data-x attribute | [data-ticker] | |
[data-x="val"] | Elements where data-x="val" | [data-ticker="AAPL"] | |
[data-x^="pre"] | data-x starts with "pre" | [data-id^="user-"] | |
[data-x$="suf"] | data-x ends with "suf" | [href$=".pdf"] | |
[data-x*="sub"] | data-x contains "sub" | [class*="btn"] |
Pseudo-Selectors
| Selector | Matches | Example | |
|---|---|---|---|
:first-child | First child of parent | li:first-child | |
:last-child | Last child of parent | li:last-child | |
:nth-child(n) | Nth child of parent | tr:nth-child(2) | |
:nth-child(odd) | Odd children | tr:nth-child(odd) | |
:nth-child(even) | Even children | tr:nth-child(even) | |
:not(selector) | Elements not matching | div:not(.hidden) | |
:empty | Elements with no children | p:empty |
Practical Examples
Updating Multiple Elements
Targeting by Data Attribute (Dynamic Content)
Table Row Styling
Best Practices
1. Prefer component_id Over Selectors
2. Use Data Attributes for Dynamic Content
3. Avoid Overly Specific Selectors
4. Test Selectors First
Use browser DevTools to test selectors:
- Open DevTools (F12)
- Go to Console
- Type:
document.querySelectorAll(".your-selector") - Verify it matches expected elements
Performance Considerations
component_id→ DirectgetElementById(fastest)- ID selector (
#myid) → Very fast - Class selector (
.myclass) → Fast - Complex selectors → Slower, may need traversal
- Universal selector (
*) → Slowest
For frequent updates (animations, live data), prefer component_id or simple selectors.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingpywry/pywry/mcp/skills/css_selectors/SKILL.md
Popularity
- Repository stars
- 89
- Repository forks
- 7
- 7-day trend score
- 22
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/deeleeramone/pywry/css-selectors)