Passing data to alternative snippets

Using the snippet helper and the alternative snippets syntax, how can I pass data to my snippets? This doesn’t seem to work:

<?php snippet(['snippet1', 'snippet2', 'snippet3'], $data) ?>

Do you mean different data arrays to each snippet or the same data?

The same data in my specific case (didn’t expect different data arrays to be support to be honest).

Okay, it looks like passing data actually works but I was passing a variable names $page and that specific name doesn’t work.

Should work in the same way as for single snippets:

<?php snippet(['snippet1', 'snippet2', 'snippet3'], ['page' => $page]) ?>

Okay, found my mistake: the $page variable is not the problem, I was setting it to the wrong value, mixing up two different foreach loops.

Passing variables works as expected. Sorry!