react-redux 6.0.0

Abierto
#172 12 comentarios 1 reacción 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
25/100
Tipo de issue
Error
Claridad
Necesita aclaración
Estado de actividad
Estancado
Stack tecnológico
javascript, react, redux
Área
frontend

Línea de trabajo

Comienza con la función onLoad y el comportamiento de mapStateToProps descritos en la issue, y después lee la issue enlazada de react-redux y las notas de la versión sobre el cambio de Context.Provider. Se considera terminado determinar cómo deberían comportarse el cuarto parámetro de contexto y el estado del reducer inyectado, y documentar o validar las actualizaciones resultantes de los componentes.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Just ran into an issue with the new way react-redux behaves.
You can see more details about it in this thread: https://github.com/reduxjs/react-redux/issues/935#issuecomment-446515270

As we can see from the last release of react-redux 6.0.0: https://github.com/reduxjs/react-redux/releases

Behavior Changes
Any library that attempts to access the store instance out of legacy context will break, because we now put the store state into a <Context.Provider> instead. Examples of this include connected-react-router and react-redux-subspace. (The current implementation does also put the store itself into that same context. While accessing the store in context is not part of our public API, we will still try to make it possible for other libraries to access it, with the understanding that this could break at any time.)

This makes the onLoad function not working properly. The fourth parameter context is no more populated with the store.
Although it is not a real issue for me, as I use redux-reducers-injector (I'm the maintainer), I have a reference of the store that I can use, and can use replaceReducer.
The real issue is that even with injecting my reducer correctly, the mapStateToProps will not reflect this change in its first parameter state and I won't be able to display my component correctly.

You can read more about this issue in the link I post above on the react-redux project: https://github.com/reduxjs/react-redux/issues/935#issuecomment-446515270

Feel free to ask me more information about this.

Lenguaje dominante
JavaScript
Estrellas
1.7k
Forks
80
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de faceyspacey/react-universal-component

Todos los issues de faceyspacey/react-universal-component

Issues similares

Más issues de JavaScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.