Simplify conjunctive case in Twig by using loop.last

Created on 25 January 2025, 4 months ago

Problem/Motivation

In #3293086-14: Apply spaceless to templates to remove whitespaces β†’ , @mortona2k pointed out that we could use Twig's loop.last feature for the conjunctive case.

I didn't see an immediately-obvious way to incorporate it, but I think it would make the code simpler and easier to understand.

Proposed resolution

Review Twig's loop.last feature. See if using it makes the logic simpler.

Remaining tasks

  1. Write a patch
  2. Review and feedback
  3. RTBC and feedback
  4. Commit

User interface changes

None.

API changes

None.

Data model changes

None.

✨ Feature request
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada mparker17 UTC-4

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024