Framework updates

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2026-03-12 19:09:07 +00:00
parent 3294fc7337
commit daa9bb2fb1
47 changed files with 2495 additions and 525 deletions

View File

@@ -33,6 +33,19 @@ class Jqhtml_Integration {
* This runs during framework_modules_define, before any DOM processing.
*/
static _on_framework_modules_define() {
// ─────────────────────────────────────────────────────────────────────
// SSR Preload Data Injection
//
// If the page was SSR-rendered, window.rsxapp.ssr_preload contains
// captured component data from the SSR server. Seed jqhtml's preload
// cache so on_load() is skipped for components with matching data.
// Must happen before component registration / DOM hydration.
// ─────────────────────────────────────────────────────────────────────
if (window.rsxapp && window.rsxapp.page_data && window.rsxapp.page_data.ssr_preload && typeof jqhtml.set_preload_data === 'function') {
jqhtml.set_preload_data(window.rsxapp.page_data.ssr_preload);
console_debug('JQHTML_INIT', 'SSR preload data seeded: ' + window.rsxapp.page_data.ssr_preload.length + ' entries');
}
// ─────────────────────────────────────────────────────────────────────
// Register Component Classes with jqhtml Runtime
//
@@ -135,6 +148,12 @@ class Jqhtml_Integration {
*/
static async _on_framework_modules_init() {
await jqhtml.boot();
// Clear any remaining SSR preload data after hydration completes
if (typeof jqhtml.clear_preload_data === 'function') {
jqhtml.clear_preload_data();
}
Rsx.trigger('jqhtml_ready');
}
}