If you're talking about "any boat" the wind can be abeam. But the tri-foiler in the link is a 40+ knot boat and if you look at it sailing in the video at the bottom of this link Hobie TriFoiler History
you'll see that the sails are sheeted in as much as possible whichever direction the boat is sailing in. That only works when the wind is forward of the beam. As it passes the speed of the wind and accelerates, which it does very quickly, the wind moves way forward. As long as the boat is going at speed it's close hauled.