Decide who is responsible for sourcing items. If you are planning a weekly meal prep for example you may want to tell everyone to bring the items needed for the amount they would like to prepare. This is also a good idea for shopping preferences for example you have two friends, one who only shops at Whole Foods and the other Aldi.
If you are planing to prepare and then sit down to eat the meal together you still have choices. You can assign out items for your guests to bring, split the bill or you can shop for the items and absorb the cost. If you do all the shopping for a meal, you have the peace of mind that you have all the ingredients and on time.