Skip to content

Commit

Permalink
fix: Transition double-rendering
Browse files Browse the repository at this point in the history
  • Loading branch information
gbj committed Sep 20, 2023
1 parent 43b58bf commit f85bfd3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions leptos/src/transition.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use leptos_dom::{Fragment, HydrationCtx, IntoView, View};
use leptos_macro::component;
use leptos_reactive::{
create_isomorphic_effect, create_rw_signal, use_context, RwSignal,
SignalGet, SignalSet, SignalSetter, SuspenseContext,
SignalGet, SignalGetUntracked, SignalSet, SignalSetter, SuspenseContext,
};
use std::{
cell::{Cell, RefCell},
Expand Down Expand Up @@ -125,7 +125,7 @@ where
let suspense_context = held_suspense_context.borrow().unwrap();

if cfg!(feature = "hydrate")
|| !first_run.get()
|| !first_run.get_untracked()
|| (cfg!(feature = "csr") && first_run.get())
{
*prev_children.borrow_mut() = Some(frag.clone());
Expand Down Expand Up @@ -161,7 +161,7 @@ fn is_first_run(
false
} else {
match (
first_run.get(),
first_run.get_untracked(),
cfg!(feature = "hydrate"),
suspense_context.has_local_only(),
) {
Expand Down

0 comments on commit f85bfd3

Please sign in to comment.