Skip to content

Reorganize frontend events and simplify view binding documentation - #128

Merged
oblomov-dev merged 1 commit into
mainfrom
claude/docs-update-check-2ow7pw
Jul 22, 2026
Merged

Reorganize frontend events and simplify view binding documentation#128
oblomov-dev merged 1 commit into
mainfrom
claude/docs-update-check-2ow7pw

Conversation

@oblomov-dev

Copy link
Copy Markdown
Member

Summary

This PR reorganizes the frontend events documentation with improved categorization and adds comprehensive documentation for control method invocation. It also simplifies the view binding API by removing the now-obsolete view parameter from _bind() calls and clarifying the single unified model architecture.

Key Changes

Documentation Reorganization

  • Frontend events (docs/cookbook/event_navigation/frontend.md):

    • Reorganized event constants into logical groups: Framework, Actions, and Control calls
    • Added new section "Calling control methods on the frontend" explaining control_by_id, control_global, and binding_call events
    • Documented positional argument handling for control method calls
    • Added table clarifying which events accept which arguments
    • Documented the view parameter for scoping control lookups to specific views (popup, popover, nested, etc.)
    • Included migration note about the view parameter moving from t_arg to a dedicated importing parameter
  • Nested views (docs/cookbook/view/nested_views.md):

    • Removed view parameter from all client->_bind() calls (now defaults to main view)
    • Renamed section from "Routing Bindings to the Right View" to "Refreshing the Right View"
    • Clarified that all bound data lives in a single unified client-side model regardless of view
    • Added table showing which refresh method to call for each view type (main, nested, nested 2nd)
    • Added deprecation note explaining that the view parameter is now inert and kept only for backward compatibility
  • Follow-up actions (docs/cookbook/expert_more/follow_up_action.md):

    • Added new section "Calling a control method" with examples of using control events in follow_up_action()
    • Documented the view parameter for scoping control lookups in follow-up actions
  • XML templating (docs/cookbook/view/xml_templating.md):

    • Minor text correction (incomplete line fix)

Notable Implementation Details

  • The changes maintain full backward compatibility — code passing the view parameter to _bind() continues to work
  • The unified model architecture simplifies data management while the view-specific refresh methods (view_model_update(), nest_view_model_update(), etc.) control which rendered view receives updates
  • Control method invocation uses positional arguments with empty slots represented as `` to maintain argument positions

https://claude.ai/code/session_01NjYGeMm8yvpJhavp6hdGyN

… parameter

- nested_views: the per-view model separation is gone (all _bind data goes to
  one root model) and _bind's view parameter is now an inert no-op; rewrite the
  routing section to choose the target view via the matching
  ..._view_model_update() call and drop the no-op view= from the examples
- frontend: refresh the stale cs_event listing and document the whitelisted
  control_by_id/control_global/binding_call calls plus the new view importing
  parameter on _event_client
- follow_up_action: document the whitelisted control calls and the view
  parameter
- xml_templating: drop a leftover duplicate _bind reference from the
  _bind_edit sweep

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NjYGeMm8yvpJhavp6hdGyN
@oblomov-dev
oblomov-dev merged commit ee56f9e into main Jul 22, 2026
@oblomov-dev
oblomov-dev deleted the claude/docs-update-check-2ow7pw branch July 22, 2026 01:03
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.

2 participants