does not tell us much. Please be more specific about what you expect and what actually happen.
Beside of this, I guess you will have two class attributes on you first item, because your class="slide" might appear everywhere, including the first item.
Just saw, that your $item variable seems not to be defined, at least not in this code snippet.
Again, help could be provided better if we would now what really happens or not.
Hey thanks for your reply.
I need to have the class slide on all my elements and add the active class only on the first element. I found this to help me: https://getkirby.com/docs/cookbook/templating/loops#first-and-last-items.
But if I try to reproduce this, my page shows the error message from Kirby.