Skip to content

Commit

Permalink
closes #13
Browse files Browse the repository at this point in the history
  • Loading branch information
stla committed Mar 23, 2024
1 parent 5596d21 commit e44bc1a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ list of jsTree core options. For advanced usage.
- There was a JavaScript error occurring in Shiny apps when the browser window
was resized while using a jsTree grid in the app. It has been fixed.

- When a `jstree` had some reactive dependencies in a Shiny app, it was not
re-rendered when these dependencies were updated.


# jsTreeR 2.5.0 (2023-12-19)

Expand Down
6 changes: 6 additions & 0 deletions inst/htmlwidgets/jstreer.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,12 @@ HTMLWidgets.widget({

return {
renderValue: function(x) {

if($el.hasClass("jstree")) {
$("#" + el.id + "-search").remove();
$el.jstree(true).destroy();
}

var plugins = ["themes"];
if(x.checkbox) {
plugins.push("checkbox");
Expand Down

0 comments on commit e44bc1a

Please sign in to comment.