Deprecate $variables['view'] for node.html.twig

Created on 2 July 2024, 11 days ago
Updated 10 July 2024, 3 days ago


Views module adds $variables['view'] to node templates.

This is impossible to provide cacheable metadata for, because we don't have the render context of the view. I've also never seen it used.

We should deprecate it in 11.1.0 for removal in 12.0.0

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

๐Ÿ“Œ Task

Needs work


11.0 ๐Ÿ”ฅ

Node systemย  โ†’

Last updated about 23 hours ago

No maintainer
Created by

๐Ÿ‡ฌ๐Ÿ‡งUnited Kingdom catch

Live updates comments and jobs are added and updated live.
  • Novice

    It would make a good project for someone who is new to the Drupal contribution process. It's preferred over Newbie.

Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @catch
  • ๐Ÿ‡ฌ๐Ÿ‡งUnited Kingdom catch
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia nishtha.pradhan

    nishtha.pradhan โ†’ made their first commit to this issueโ€™s fork.

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia nishtha.pradhan

    Added a deprecation notice for use $variables['view'].

  • Pipeline finished with Failed
    9 days ago
    Total: 317s
  • Pipeline finished with Failed
    9 days ago
    Total: 321s
  • Pipeline finished with Failed
    8 days ago
    Total: 175s
  • Pipeline finished with Failed
    8 days ago
    Total: 853s
  • Pipeline finished with Failed
    8 days ago
    Total: 179s
  • Pipeline finished with Success
    8 days ago
    Total: 552s
  • Status changed to Needs review 8 days ago
  • Status changed to Needs work 7 days ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia ankitv18

    I've reviewed the MR and left a comment.
    Please cover the deprecation part and revert the other changes.

    Note: Issue URL should be replaced with the document URL of the deprecation.

    cc: @catch

  • Pipeline finished with Success
    5 days ago
    Total: 510s
  • Status changed to Needs review 5 days ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia nishtha.pradhan

    Thank you for your feedbacks @guptahemant & @ankitv18.
    I have worked upon them and update the MR.
    Please do let me know if any other changes are required.

  • ๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand quietone New Zealand

    @nishtha.pradhan, thanks for creating a change record for this issue, that is most helpful. Change records are published after an issue is committed and doing that is part of a core committer's tasks. So, please leave change records at draft. Thanks.

  • Status changed to Needs work 3 days ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States smustgrave

    Left a comment on the MR.

    But can we also add a deprecation test for this.

Production build 0.69.0 2024