I think the amount of Vitamin D needed is provided well before you start to get sunburn.
I’m in southern Arizona, so I don’t worry about vitamin D supplements. Sunscreen is more useful...
Living in the northeast, I take no Vit D supplements during the summer, but I do take cholecalciferol during the fall, winter and spring.
Ah........ but the suncreen actually BLOCKS Vitamin D absorption, so even here in AZ we need extra D....