Allium leaf miners are the larva(maggots) of a little fly that lays its eggs on the leaves of our alliums (onions, shallots, garlic, leeks, etc). The larvae hatch out and tunnel down, eating and growing as they go, then pupate in the bulb area. Their damage causes the plants to become distorted, and opens them up to fungal disease. There are some good pictures to help identify them on the Allotments & Gardens web site.
The RHS have some useful advice about how to cope, as does Garden Organic (members only, unfortunately). There is no cure – only prevention, which means destroying infected plants to kill the larvae and pupae, and keeping the flies from laying their eggs on our crops by covering them with nets. The flies are quite small, and the RHS advise using very fine mesh (0.8mm) netting, as the standard “fine” mesh (1.3mm) is not reliable.
The adult flies are active in spring (March to June) and again in the autumn (September to November), which is when you need to cover your crops. These dates are a bit uncertain, as the pest is new here and we are still learning about it.