Question: How is the stack lifecycle (`activities` array) intended to be managed?
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Documentación
- Claridad
- Necesita aclaración
- Estado de actividad
- Estancado
- Stack tecnológico
- react, typescript
- Área
- frontend, mobile-dev
Línea de trabajo
Comienza con la documentación oficial de useStack() y del ciclo de vida de las actividades en torno a push, replace y pop. Determina si el array está diseñado intencionadamente para ser solo de adición y si volver al root debería recortarlo o seguir siendo observable mediante transitionState, isTop e isActive. Se considera completado cuando se documenta el comportamiento previsto o se define un requisito claro de restablecimiento/recorte.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
According to the official documentation, the useStack() hook can be used to access the stack state within UI components. However, when examining the activities array returned from useStack(), I noticed that its length increases by one each time the push or replace functions are called, and does not decrease when the pop function is invoked.
It is true that by checking properties such as transitionState, isTop, or isActive, one can determine which screen the user is currently viewing. Still, if the user repeatedly performs push or replace operations, the array continues to grow regardless of what the user actually sees. Intuitively, in scenarios such as when the user has finished navigating and returned to the root activity, one would expect the array to reset. Without some form of cleanup, the length of the array could, at least in theory, grow without bound.
As far as I know, Stackflow does not currently provide an API to reset or trim the stack state array in this manner. Of course, since Stackflow is obviously well-designed to be easily extended and customized through plugins, I imagine it would not be very difficult for me to implement additional functionality by myself if needed. That said, before proceeding, I would like to confirm whether my understanding aligns with the framework’s intended design. Or am I perhaps misunderstanding how the lifecycle of the stack is meant to be managed?
- Lenguaje dominante
- TypeScript
- Estrellas
- 1k
- Forks
- 114
- Merge medio
- 59 min
- PR fusionados (30 d)
- 4
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de daangn/stackflow
-
스와이프 백 애니메이션 덜컥임 이슈Quizá libre de nuevo @Shennng la tomó hace 222 días y no hay ningún pull request abierto. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
-
Vue3 지원 계획Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
다른 호스트로 이동해야할 때 처리에 관하여Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 18/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 30/100
-
App 푸시로 앱에 들어왔을 때 뒤로가기 시 메인으로 이동Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
Todos los issues de daangn/stackflow
Issues similares
-
bnv-manager-v2: accept_invite creates the Mailcow domain admin before the commitPosiblemente ocupada @myOmikron la tomó hoy. Abiertobug ready-for-agent
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
-
Windows: mio 1.2.3 named-pipe use-after-free panics the native IPC broker and hangs every toolAbiertoplatform:windows tool triaged wontfix
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
nicolettas-muggelbude/RechnungsFee#448 ·
Los mantenedores suelen responder en 1 día
-
Android bug feature/error-tracking react-native team/error-tracking
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
PostHog/posthog-js#5310 · 1 comentario ·
Los mantenedores suelen responder en 1 día