Skip to content

Conversation

@martinRenou
Copy link

No description provided.

protected onUpdateRequest(msg: Message): void {
// This is a no-op.
// @ts-ignore
this.parent?._update();
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is obviously hacky.

We can't call this.parent.update() since it would result in an infinite update loop.

Happy to discuss a better approach though. Maybe introducing a new public rerender method in the parent?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think adding rerender sounds fine if required.

Copy link
Owner

@krassowski krassowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @martinRenou! What would you think about opening this as a PR against JupyterLab (disregarding the switch to defer)? My thinking is that this can be merged and tested before we are ready to merge the change to defer by default.

protected onUpdateRequest(msg: Message): void {
// This is a no-op.
// @ts-ignore
this.parent?._update();
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think adding rerender sounds fine if required.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants