Closed
Conversation
|
Contributor
✅ Deploy Preview for patternfly-elements ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
Member
Author
|
closing in favour of #2893 |
bennypowers
added a commit
that referenced
this pull request
Apr 7, 2025
* chore: nvm use lts * chore: bump lit-labs/ssr * chore: bump lit/context * fix: update context usage for ssr * fix: use lit-ssr html function * fix(core): rely on lit's dom-shim * chore: update and align lit version * fix(core): ssr connected callback * fix(elements): ssr connected callbacks * fix(elements): table th role from context instead of dom * feat(core): wip slots decorator * fix(core): empty array check * fix(core): remove need for static decorator for ssr slot hints * fix(core): client-side slot controller doens't use isServer * fix(core): ssr-hint-has-default-slotted attr name * test: ssr demos backported from #2505 * chore: ssr dev packages * chore: deps * docs: build elements * docs: format * chore: revert ssr we'll have to either patch or reimplement like we did in rhds * style: lint * docs: remove preloads * docs: changeset
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
👉 DRAFT PR DO NOT MERGE 👈
This approach is experimental and requires discussion before pursuing. This PR is a PoC only. However there is a lot to get excited about. for example, we could load a
/elements/pf-icon/pf-icon-ssr.jsat ssr time which, instead of setting up a bunch of client side js to fetch and render the icon, would just dump the contents of the svg into shadow root withawait readFile, at SSR time.Read more: https://lit.dev/docs/ssr/overview/
TODO:
use export conditions instead of
isServerWhat I did
has-slottedhost attrTesting Instructions
Notes to Reviewers
Problem: Lit-SSR can't access the children, whereas SlotController relies on knowledge about the children.
Proposal: read
has-slotted="a,b,c"attr on SlotController hosts. This has limitations:hasSlottedin connectedCallback, only inrender(lit may relax this limitation in the future)