Skip to content

docs(removeAttributesBySelector): properly document and check types#2215

Merged
KTibow merged 2 commits intosvg:mainfrom
KTibow:remote-attributes-by-selector-docs-changes
Apr 9, 2026
Merged

docs(removeAttributesBySelector): properly document and check types#2215
KTibow merged 2 commits intosvg:mainfrom
KTibow:remote-attributes-by-selector-docs-changes

Conversation

@KTibow
Copy link
Copy Markdown
Collaborator

@KTibow KTibow commented Apr 9, 2026

I'm uncertain if the switch to matches in #1978 is a good idea perfwise. But it has a subset which are clearly good ideas, so this PR is just those.

  • better documentation
  • better types
  • warning on incorrect configuration
  • more tests

KTibow and others added 2 commits April 9, 2026 09:54
…definitions

Expand and clarify the plugin's documentation with individual parameter
descriptions for selector and attributes. Add TypeScript parameter types
via JSDoc typedefs and export them in lib/types.ts. Add parameter validation
and warning to prevent runtime errors when plugin is not configured or
misconfigured. Update type annotation to use RemoveAttributesBySelectorParams.
Add tests to ensure plugin is a no-op when not configured.

Co-Authored-By: soren121 <soren121@users.noreply.github.com>
@KTibow KTibow merged commit eb4c8b6 into svg:main Apr 9, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant