Using wp_interactivity_state to render derived state server side #59447
Closed
ajgagnon
started this conversation in
Interactivity API
Replies: 1 comment 2 replies
-
Ah, I see now it should be set statically, but there are future plans for getting the context.
|
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
First off, hats off to the team on this project! This has honestly been great to work with so far - it's obvious how much time and energy went into this and the API is outstanding.
I am wondering how to ensure derived state on
wp_interactivity_state
should be handled so SSR processing of directives work. Here's a contrived example:For example:
Right now, I am working around this by setting the context in the block context. This works, of course, I'm just wondering if there is a best practice here.
Beta Was this translation helpful? Give feedback.
All reactions