Can links be hidden while there are connection relationships between nodes?
In other words, can links be as short as possible, preferably 0?
Or can nodes be connected directly?
You can set their opacity to 0. But I do not know if that solves the problem that you have. What is it that you want to achieve by making the links unseen? Such links could be very confusing to the user.
Setting their visible property to false might also work, but that would more drastic. Some code treats invisible parts as if they did not exist, which might not be what you want. Setting opacity only affects rendering.