Skip to content

Passing object into partial fails if locals: not used #378

@yusufali2205

Description

@yusufali2205

Passing objects to partial fails if the below format is used:
json.comments @post.comments, partial: 'comments/comment', as: :comment, show: false

It succeeds if locals option is used:
json.comments @post.comments, partial: 'comments/comment', locals: { show: false }, as: :comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions