I'm thinking this option is more likely to be useful as a ray visibility option like for cycles.
I'm not really keen on adding more EEVEE specific option that makes is farther from cycles.
However I do see the use case of this feature so I'm on the fence.
The patch itself is good.
Apply clang format.
Use an epsilon here. 1e-8 should do it.