Skip to content

Render not getting called using helper method when additional component added via ajax #338

@nao-de

Description

@nao-de

I have an infinite pagination gem active on my page. It basically runs an ajax script when it hits the bottom of the page and loads more posts, which exist as react_components. The helper method is able to generate the react_component and add it as HTML (see below), but the render method is never actually called, so it just exists as an empty div. The components loaded initially with the page work, just not additional components delivered via AJAX.

<
div data-react-class="MainPostBox" data-react-props="{"parentID":18,"imageSource":"test.png","postTitle":"JODKPTSJ","postPrice":"$5,174.54","postCommentsCount":"0","userName":"user #3","initialVoteCount":0,"initialHasUpvote":false,"initialHasDownvote":false,"hasDownvoteButton":false,"votableType":"posts"}">

(had to delete some of the brackets in the div tags because markdown was counting them as comments)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions