There are quite a few techies who move to SF, work for the hot unicorn for 4 years, and live extremely cheaply. They don't buy housing because they don't intend to stay in SF (and besides, who wants to buy a house in SF?), but when they "retire" they've got a few million in stock options. They can buy a house, they just don't want to, because their living situation is temporary.
I suspect that a lot of the housing boom going on around the country now is because the rich techies in SF no longer have to stay in SF.