שו”ת יביע אומר חלק ד – אורח חיים סימן לח
Question: May one break a piece of chocolate or cookie on Shabbat, for the purpose of eating, if the food has writing on it?
Answer: If the writing is made of cream or food coloring, you may break the cake/chocolate with one’s hand, but if you break it with your mouth, that is preferable. When the writing is made of the batter/chocolate itself, you may be lenient, especially if the writing is not in Hebrew.
Reason: This question generates quite a lot of debate and a lengthy responsum of twelve pages.
Questions that are discussed and taken into consideration are: Is eating or breaking the cookie considered erasing even though you are eating it immediately and have no intention of writing? Is the writing “inscribed” while the cake or chocolate is still being made, or added after? These acts would desecrate Shabbat.