Hey @trz-justin-dev! You've probably noticed that custom components are rendered within an iframe, making it a little challenging to communicate with the parent window. This should be the perfect use case for postMessage but I've had some trouble getting it to work. I'm fairly certain it's a byproduct of the way the different elements are sandboxed but there doesn't seem to be a good workaround. I'll keep playing around with that, though, because I really want to get it to work.
In the meantime - it's a little wacky, but you could probably create a dummy resource query that doesn't actually do anything but watches customComponent.value. In its success callback, you could trigger a JS query that updates the variable. Would that work for you?