Skip to content

Commit

Permalink
fix: remove unnecessary nextTick
Browse files Browse the repository at this point in the history
  • Loading branch information
NiklasNeugebauer committed Jan 20, 2025
1 parent 2f8c098 commit 2f97079
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions nicegui/static/nicegui.js
Original file line number Diff line number Diff line change
Expand Up @@ -382,16 +382,14 @@ function createApp(elements, options) {

await Promise.all(loadPromises);

Vue.nextTick(() => {
for (const [id, element] of Object.entries(msg)) {
if (element === null) {
delete this.elements[id];
continue;
}
this.elements[id] = element;
replaceUndefinedAttributes(this.elements, id);
for (const [id, element] of Object.entries(msg)) {
if (element === null) {
delete this.elements[id];
continue;
}
});
this.elements[id] = element;
replaceUndefinedAttributes(this.elements, id);
}
},
run_javascript: (msg) => runJavascript(msg.code, msg.request_id),
open: (msg) => {
Expand Down

0 comments on commit 2f97079

Please sign in to comment.