Hi, this is a great enhancement! I have a suggestion for further customization regarding the document title updates.
Could we allow specifying the update_title behavior on a per-callback basis?
My reasoning is that not all callbacks require the same title update strategy. The way I would divide callbacks is into two categories -
-
User-triggered callbacks: For these (e.g., button clicks, form submissions), it would be very beneficial to set a dynamic title like update_title="Updating..." to provide immediate user feedback during processing.
-
Automated/Background callbacks: For callbacks like dcc.Interval (which I use for periodic updates or access control checks), changing the document title would be distracting and unnecessary. For these, I'd ideally want to explicitly disable the title update, perhaps by setting update_title=None.
While I have seen suggestions on using clientside callbacks for this, I believe allowing this granular control within dash would significantly improve the user experience by enabling context-appropriate title changes without polluting the title bar for background operations and the developer experience by not expecting the developer to write a clientside callback for every relevant callback. Thanks!
Additional context
Old PR that allows global enable or disable of Document Title update and changing the text of the Document Title when updating #1343
Similar Issue but focuses more on Location and Tabs
Hi, this is a great enhancement! I have a suggestion for further customization regarding the document title updates.
Could we allow specifying the update_title behavior on a per-callback basis?
My reasoning is that not all callbacks require the same title update strategy. The way I would divide callbacks is into two categories -
User-triggered callbacks: For these (e.g., button clicks, form submissions), it would be very beneficial to set a dynamic title like update_title="Updating..." to provide immediate user feedback during processing.
Automated/Background callbacks: For callbacks like dcc.Interval (which I use for periodic updates or access control checks), changing the document title would be distracting and unnecessary. For these, I'd ideally want to explicitly disable the title update, perhaps by setting update_title=None.
While I have seen suggestions on using clientside callbacks for this, I believe allowing this granular control within dash would significantly improve the user experience by enabling context-appropriate title changes without polluting the title bar for background operations and the developer experience by not expecting the developer to write a clientside callback for every relevant callback. Thanks!
Additional context
Old PR that allows global enable or disable of Document Title update and changing the text of the Document Title when updating #1343
Similar Issue but focuses more on Location and Tabs