I’m trying to bind to navigator.getVRDisplays()
in Bucklescript. The problem is while navigator
is always there, navigator.getVRDisplays
is undefined
if VR isn’t supported in the environment. It seems like I need to somehow combine bs.optional
and bs.send
, but the things I’ve tried don’t seem to work, I only get one or the other.
How should I create this binding?