Q.Leaf Miner Totally Destroyed Spinach Crop/will Plant Spinach In Another Spot Next Yr.
What vegetable can I plant where spinach was that won’t get leaf miner?

Certified GKH Gardening Expert
It's best not to plant any vegetables where leaf miners have been because the pupa overwinter in the soil. However, if you plant a non-leafy vegetable, control shouldn't be needed as the leaves wouldn't be the edible part. In those cases, remove leaves as you see symptoms.
Prevention is key. Look for resistant varieties of vegetables. In regard to spinach and lettuce, where the damage is in the edible part of the plant, the best thing to do for seedlings is to cover them with a protective cloth such as row covers. Then the fly is unable to lay eggs. (This only works if you haven't seen leafminer damage in at least a year in the planted area due to overwintering pupae.)
http://ipm.ucanr.edu/PMG/GARDEN/VEGES/ENVIRON/protectivecov.html
http://ipm.ucanr.edu/PMG/GARDEN/VEGES/PESTS/vegleafminers.html
https://extension.umn.edu/yard-and-garden-insects/leafminers