Since you want to be alert, eating a big meal just before meditating is not advised, as of course digesting a big meal makes you sleepy. However, if you are so hungry that all you will be able to do when you try to meditate is imagine juicy hamburgers and other favorite foods, please eat a little something! Common sense goes a long way in meditation too.
It’s also a good idea to avoid getting yourself worked up before meditating by checking your messages on your phone, news feeds, etc. Sometimes this is unavoidable, and meditation will help you get over it, but in general, especially early in your practice, you want to create as calm a starting environment as possible.