Hello! I just happened to notice in our DEV environment, the {{categories}} variable is behaving differently than in our PROD environment.
In the component file lw_cal_event_detail.html, there is the following snippet of syntax that should display only the first category of an event:
{[ if (obj.categories) { ]}
<ul class="event-header--types">
{[ if (obj.categories) { ]}
<li class="type">{[ print(categories[0]); ]}</li>
{[ } ]}
</ul>
{[ } ]}
In PROD, I see this:
In DEV, I see this:
When I update the code to this:
{[ if (obj.categories) { ]}
<ul class="event-header--types">
{[ if (obj.categories) { ]}
<li class="type">{{categories}}</li>
{[ } ]}
</ul>
{[ } ]}
The output of the variable looks like this, which would explain why categories[0] returned ‘<’:
<span class="lw_item_event_types">Free<span class="lw_comma">,</span> Information sessions<span class="lw_comma">,</span> Lectures & seminars</span>
The {{categories}} variable is used in other components like lw_cal_categories.html, and when I ran a test there, categories[0] actually returned the first event type and not the ‘<’ chracter.
The code on both servers are the same, but the LiveWhale versions are different:
DEV is v2.21.0
PROD is v2.14.0
I combed through the recent release notes but didn’t find anything related to components.
I’m a little stumped on this one at the moment!
Thank you for any insight anyone may have