You'll want to avoid the big floating rafts of the stuff, but otherwise, loose weed often just gets brushed aside. Weed which is still rooted in the bottom is a different story and can make any kind of progress almost impossible. If you sail on a lake which has been invaded by Eurasian Milfoil you'll often have to invert the board and swim it out to clear water.
If weed DOES become wrapped on the foil structure you can sometimes do a hard backwind tack and clear it, but you'll usually have to jump off and do it by hand. My experience is that a single strand of milfoil the size of a big piece of spaghetti on the stab makes it impossible to take off - kind of amazing.
We have weed growing near the shore where we launch and have just one or two strands around the mast can absolutely kill low wind potential and make foiling much more physical even if you do manage to take off. I jump in the water or reach below and check the foil mast every time I sail out and I try to avoid going too close to shore unless I'm sailing back to the beach. Sailing backwards or tacking doesn't always do the trick.
Foiling is based on the foil generating very little drag. When you add just a bit of drag from some weed, it actually has a much larger effect than on a finned board and the shape & size of the foil assembly makes it much harder to shed it.
It depends a lot on the weed and your speed. At my home spot on Cape Cod, we often have thick weed, which prompts many windsurfers to use weed fins. I've never had a problem foiling, but my wife used to get of her foil to clear weed by hand several times a session when it was bad.
At a different spot (Hatteras in the fall, sound-side), it's a different story. The sea grass there is thin and so clingy that regular weed fins sometimes don't shed it. When it's bad, you better know how to sail backward to shed it, and then get going right away. Doable when windfoiling, hard to impossible when winging. My wife ended up with a shoulder injury which she thought was partly due to so much more drag from the weeds. She also had very little fun, which may be worse, since it makes future trips to Hatteras less likely
.
We have huge areas of marsh grass in the bays and rivers where I often sail. The dead grass floats free on the high tides and you have to sail around it and/or stop and clear it or your parked.
Which makes you wonder about marine biologists. As if this penguin is going to cruise about like nothing's unusual?

Depends on the type of weed and how much of there is.
my experiences with weed, you collect a few strands of it and it drags you down off the foil constantly. The higher you fly, the worse the effect is. The weed we get here in WA is ribbon weed. It doesn't break easily. If you catch some, you need to either jump off and clear it, or tack and let the board reverse a little half way through. Jumping off to clear it is frustrating, especially when you've picked up more of it two minutes after you get going again. And reversing to clear it is a bit hit and miss.
thats why i avoid weed infested spots like the plague when foiling. But if its a spot where you know you might pick up a strand or two over the course of a session then probably worth it.
I've been pumping like crazy, feeling like I should've been flying, only to find a big clump of seaweed around the foil mast. I haven't yet had the effect of a single strand or whatnot on the foil, but I've definitely had issues getting going with the big clumps.
had two 1/8" wide strands of seaweed get caught in the gap between the front of the stabilizer and the fuselage (1 stab. shim caused the slight gap), killed light wind foiling. Was not a weedy day, so now I need to be very aware of how the foil is performing, and if I am not getting up easily remember to check for seaweed. Does not happen often, we usually have much thicker seaweed and I have not had a problem with that, though I do avoid it when getting up, but once up can ignore it unless really clumpy. What can happen is a clump can wrap around one side of the wing in flight cause loss of lift, that will cause the other side to corkscrew the foil/board resulting in a crash.
About mid July the weeds in the Columbia Gorge get really bad at some sites. Slogging out through the weeds, dropping in, clearing your foil of 100 pounds of weeds, uphauling/waterstarting, and foiling away are facts of life. Fortunately, weeds are only in the shallows near the shore. Once you get out into deep water, no weeds except for floating clumps.