Skip to content

docs: explain shadow DOM style injection#282

Open
razchiriac wants to merge 1 commit intobitovi:mainfrom
razchiriac:docs/shadow-dom-styles
Open

docs: explain shadow DOM style injection#282
razchiriac wants to merge 1 commit intobitovi:mainfrom
razchiriac:docs/shadow-dom-styles

Conversation

@razchiriac
Copy link
Copy Markdown

Summary

  • Documents that styles from the host page do not automatically apply inside shadow: \"open\" or shadow: \"closed\" components.
  • Adds an example of extending the generated custom element and appending a stylesheet link to the shadow root in connectedCallback.
  • Notes the Vite/Tailwind pattern of emitting a CSS file and linking to the built asset.

Closes #172.

Test plan

  • pnpm dlx prettier --check docs/api.md

Made with Cursor

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.

Embedding styles in shadow DOM

1 participant