Draft
Conversation
- blocks which can be partially rendered are named Tiles (subject to change) - AlpineJS is now bundled (if opted for or if page contains Tiles) - Tiles for a page are saved upon preview or publish, NOT every time that page is saved - a Tile can be rendered by making a POST request to the same URL as the page and providing the block_id, block_data and props or simply using the refreshTile function
a lightweight Alpine-based reactive library for managing global state across scripts.
API:
set(key, value)
$reactive.set('count', 1)
$reactive.set('user', { name: "A" })
get(key)
const count = $reactive.get('count')
update(key, updater, options?)
$reactive.update('count', c => (c || 0) + 1)
$reactive.update('user', { name: "B" })
$reactive.update('count', 10)
$reactive.update('count', c => c, { skipEqual: true })
watch(key, callback)
$reactive.watch('count', (val, old) => {
console.log(old, '→', val)
})
effect(fn)
$reactive.effect(() => {
console.log($reactive.get('count'))
})
delete(key)
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #548 +/- ##
===========================================
- Coverage 63.49% 57.50% -5.99%
===========================================
Files 27 29 +2
Lines 2802 3163 +361
===========================================
+ Hits 1779 1819 +40
- Misses 1023 1344 +321 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
This PR introduces partial rendering to Builder.
Until now, Builder could only render entire pages. With this change, it can render specific blocks (currently called Tiles, name subject to change) independently, without re-rendering the full page.
This enables dynamic updates for specific sections of a page—without requiring a full page refresh—preserving client state in other section, somewhat mimicking SPA behaviour.
Demo
In the Only SSR scenario, dynamic values (e.g., comments) can only be updated via a full page refresh.
With partial rendering, the comments section can be updated independently:
Screen.Recording.2026-04-17.at.9.47.35.AM.mp4
The counter section demonstrates whether a full page refresh occurred, since its state is entirely client-side:
Screen.Recording.2026-04-17.at.10.17.10.AM.mp4
We can also handle cases where comments are edited or deleted after the initial render:
Screen.Recording.2026-04-17.at.10.45.06.AM.mp4
How it works
This is how Builder renders a block:
So we can theoretically render specific blocks in isolation given their inherited block data and block props. This is exactly what we do:
A Tile can be re-rendered on the client using:
Where
elcan be:Flow:
refreshTilesends a request to the server with:block_idblock_datablock_propsThe server re-renders the block using this context
It returns HTML for that specific block
The client merges the returned HTML into the existing DOM
Screen.Recording.2026-04-17.at.10.47.42.AM.mp4
Additional improvements on Block Client Scripts (QoL)
Event system for inter-block communication
dispatch(event, detail?, target?)Publish events (default target:
document)Example:
listen(event, callback)Subscribe to events
Example:
Global reactive store
$reactive: a lightweight global reactive storeFor more details:
28465c4