Onions make sure you cut them up really well before throwing into your pile. They will start growing more onions if you don't chop them up adequately. Worms also avoid onions, if you are vermicomposting or something.
Add leaves and water it all down pretty well. You want to be able to take a handful, squeeze it and it feels nice and damp, but not to where you are wringing water out like a sponge. If you have a small pile, cover it up with a tarp to help keep the moisture in, but if the pile is big enough you don't really have to bother. The center of the pile will heat up over a while to 130-140 and then slowly start to cool. Ideally you want to flip it when it starts to cool. If you don't have a thermometer to check, just flip every so often, give it a good mix and create a new center to cook. If you are doing it in winter, it'll take about through mid-spring before finishing up. If you do it in the summer, you might get finished within a few weeks.
Good luck and thanks for helping save some wastes.