Limenius/ReactBundle

v2.3.1 use ReactRendered 3.0 but wire wrong renderer

Mrlaminat opened this issue · 7 comments

In the file Resources/config/services.xml:

        <parameter key="limenius_react.context_provider.class">Limenius\ReactRenderer\Context\SymfonyContextProvider</parameter>

        <parameter key="limenius_react.static_react_renderer.class">Limenius\ReactRenderer\Renderer\StaticReactRenderer</parameter>

But in composer.json we require "limenius/react-renderer": "^3.0.0".

Error message:

In ReactRenderExtension.php line 35:

!!                                                                                 
!!    Argument 2 passed to Limenius\ReactRenderer\Twig\ReactRenderExtension::__co  
!!    nstruct() must be an instance of Limenius\ReactRenderer\Renderer\StaticReac  
!!    tRenderer, instance of Limenius\ReactRenderer\Context\SymfonyContextProvide  
!!    r given

This is due to the dependency injection definitions not having been updated. See https://github.com/Limenius/ReactBundle/blob/master/Resources/config/twig.xml#L12

I will try and submit a PR but that class now requires the AbstractRenderer exists as the static one is dependent on it.

My solution was to pin react-bundle to v2.1.0 which is the last working version as it depends on react-renderer v2.

Hi, I have the same issue, is there any update? Thanks for info.

Hi, I have the same issue, is there any update? Thanks for info.

I think no, you can just fix version to stable one.

just experienced it too, reactrenderer should be locked to ^2.1 in reactbundle

@nacmartin Do you plan to fix it ?

I am working on this now.

I have pushed a new version v4 with this fixed, here and in ReactRenderer. Please tell me if there is any issue.