If memory serves correctly, I think that's close to how ClickOnce worked/works? - but Windows only. One of the apps I worked on does it, but it was a homegrown framework. Definitely the sort of thing it's nice to delegate to a specialized system where possible.
Well Java Web Start could do it also I think, but none of these systems are active anymore and of course none of them were a "native" desktop experience.