First, don't put the bed against the gate. If it is, it's best to partition it with curtain cloth.
Second, the placement of the bed hinders the family's actions. If it brings inconvenience to the family's actions, then don't set it;
Thirdly, if it is a child's bed, don't be near the window. You can also use a tatami bed with a storage cabinet under it, which not only increases the storage area, but also makes full use of the room.